eos icon indicating copy to clipboard operation
eos copied to clipboard

Assertion exception on get accounts

Open jchung00 opened this issue 8 years ago • 2 comments

OS: Ubuntu 18.04 (cleos.sh is a script that runs cleos -u <http-server-address>) As shown below, get account throws an assert exception on some accounts. Using the -j option was a workaround. Several other accounts that I tested with the same command outputted account info normally, so this seems to be somewhat "random" When people on other nodes ran ./cleos.sh get account blockmatrix1, some of them got the same assert exception, while some got the normal output. The same thing happens on repeated attempts. cleos versions were the same throughout different nodes.

ubuntu@ip-172-31-17-128:~/opt/trusted$ ./cleos.sh get account blockmatrix1
privileged: false
permissions: 
     owner     1:    1 EOS8BSJrm37AEKVuFwreFXm3V7SrrKe9kLsnrvytVMqZ8ssr3N8ob
        active     1:    1 EOS7MdChGMaDeTVX21oqNMUAHPgZKJPG6uqyAjn1ymvbxaXodZyMG
memory: 
     quota:     3.252 Mb     used:     6.784 Kb   

net bandwidth: (averaged over 3 days)
767336ms thread-0   main.cpp:2584                 main                 ] Failed with error: Assert Exception (10)
a.get_symbol() == b.get_symbol(): 

ubuntu@ip-172-31-17-128:~/opt/trusted$ ./cleos.sh get account blockmatrix1 -j
{
  "account_name": "blockmatrix1",
  "privileged": false,
  "last_code_update": "1970-01-01T00:00:00.000",
  "created": "2018-06-05T16:45:09.500",
  "ram_quota": 3410084,
  "net_weight": 40000,
  "cpu_weight": 40000,
  "net_limit": {
    "used": 1720,
    "available": 1048828,
    "max": 1050548
  },
  "cpu_limit": {
    "used": 42843,
    "available": 188935,
    "max": 231778
  },
  "ram_usage": 6947,
  "permissions": [{
      "perm_name": "active",
      "parent": "owner",
      "required_auth": {
        "threshold": 1,
        "keys": [{
            "key": "EOS7MdChGMaDeTVX21oqNMUAHPgZKJPG6uqyAjn1ymvbxaXodZyMG",
            "weight": 1
          }
        ],
        "accounts": [],
        "waits": []
      }
    },{
      "perm_name": "owner",
      "parent": "",
      "required_auth": {
        "threshold": 1,
        "keys": [{
            "key": "EOS8BSJrm37AEKVuFwreFXm3V7SrrKe9kLsnrvytVMqZ8ssr3N8ob",
            "weight": 1
          }
        ],
        "accounts": [],
        "waits": []
      }
    }
  ],
  "total_resources": {
    "owner": "blockmatrix1",
    "net_weight": "4.0000 EOS",
    "cpu_weight": "4.0000 EOS",
    "ram_bytes": 3410084
  },
  "delegated_bandwidth": null,
  "voter_info": {
    "owner": "blockmatrix1",
    "proxy": "",
    "producers": [],
    "staked": 800000,
    "last_vote_weight": "0.00000000000000000",
    "proxied_vote_weight": "0.00000000000000000",
    "is_proxy": 0,
    "deferred_trx_id": 0,
    "last_unstake_time": "1970-01-01T00:00:00",
    "unstaking": "0.0000 EOS"
  }
}

jchung00 avatar Jun 07 '18 15:06 jchung00

This could happen if the EOSIO code base used to compile cleos uses a different system token than the one used for the network. Did you set the CORE_SYMBOL name to EOS on your cleos build?

The delegated bandwidth object is null which is the root cause of the default asset type entering the equation.

bytemaster avatar Jun 07 '18 19:06 bytemaster

No, it wasn't changed for the cleos build, but it was weird that some node couldn't get account while others could. Seems like it's been addressed on your commit, thanks.

jchung00 avatar Jun 07 '18 19:06 jchung00