eoscanada / eosc

Cross-platform EOSIO command-line swiss-army-knife (EOS, BOS, Telos, Worbli, etc.)
https://eosc.app
MIT License
134 stars 59 forks source link

When calling `updateauth`, keys and account names must be in alphabetical order #116

Open joshkauffman opened 5 years ago

joshkauffman commented 5 years ago

eosc does not give a good assertion when failing to updateauth. Keys and account names must be in alphabetical order, but this is not commented anywhere. We should at least add this to the --help for now.

This is what I was presented with when trying to change up until we figured it out.

{
  "code": 500,
  "message": "Internal Service Error",
  "error": {
    "code": 3050000,
    "name": "action_validate_exception",
    "what": "Action validate exception",
    "details": [
      {
        "message": "Invalid authority: {\"threshold\":2,\"keys\":[{\"key\":\"EOS7vca1TogPTeMuXwstar1NFvTxzAipVyHced8ZMugEKdBDFdnHZ\",\"weight\":1},{\"key\":\"EOS7cn6BWhccQEMhPvZyNmZ6X3ZwsjhMeav9P2fguDBFWnwEkzqLS\",\"weight\":1}],\"accounts\":[],\"waits\":[]}",
        "file": "eosio_contract.cpp",
        "line_number": 217,
        "method": "apply_eosio_updateauth"
      },
      {
        "message": "pending console output: ",
        "file": "apply_context.cpp",
        "line_number": 72,
        "method": "exec_one"
      }
    ]
  }
}