1

Two weeks ago I tried to use cleos subcommands and everything worked fine. I could set contract to the accounts I created using my own smart contract code. Now whenever I tried set contract or create account, it kept giving this error. I tried changing the config files and rebuilding eos but the program still doesn't seem to work. What can I do here?

cleos bug

cleos state

  • Hi Tim, I remember running into this error as well a couple of weeks ago, I think it was related to the an earlier version of cleos (pre 1.0.2). Which version are you running? I would suggest getting the latest, rebuilding, and make sure you do sudo make install from the build directory once the build is complete. – Vlad Jun 20 '18 at 0:50
  • @Vlad hey Vlad, how would you check the version of cleos? I ran sudo make install and restarted nodeos but still give the same error, unfortunately. – Tim Zhang Jun 20 '18 at 1:08
  • From the error, it seems that the argument value is not passed. Passed string is "". This seems to be a similar problem - github.com/EOSIO/eos/issues/3782. Look at nodeos in the same way. – smarteasy Jun 20 '18 at 2:19
1

The reason you're getting this error is because you're using the wrong flags to generate the ".abi" and ".wast" files.

Ensure you are using the "-g" flag to generate the ".abi" file and the "-o" flag to generate the ".wast" or ".wasm".

The commands you should run are: eosiocpp -o AccountPhoto.wast AccountPhoto.cpp eosiocpp -g AccountPhoto.abi AccountPhoto.cpp

Also, you may want to consider switching to the EOSIO.CDT package, which now uses eosio-cpp. The abi and wasm files are also generated in one command (instead of two).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.