bitshares / bitshares-core

BitShares Blockchain node and command-line wallet
https://bitshares.github.io/
Other
1.17k stars 643 forks source link

Show more info about Execution error: Assert Exception: static_cast<size_t>(tag) < count() #2578

Closed abitmore closed 2 years ago

abitmore commented 2 years ago

Description

When trying to transact with an older version of cli_wallet (E.G. 5.0.0) on the current chain (version 6.x), this error is returned:

Execution error: Assert Exception: static_cast(tag) < count()

Reported by multiple users.

The error appeared after explicitly set fee schedule for operation number 64-74. It disappeared after the explicit values got removed from fee schedule.

I think the error is generated by this code: https://github.com/bitshares/bitshares-core/blob/ac1cfc058633de8cfd0355fad207e5fa6e9d65f3/libraries/protocol/fee_schedule_calc.cpp#L47

Still trying to stably reproduce.

It is better to show more info for easier diagnosis when such error occurs.

Impacts Describe which portion(s) of BitShares Core may be impacted by this bug. Please tick at least one box.

Host Environment Please provide details about the host environment. Much of this information can be found running: witness_node --version.

CORE TEAM TASK LIST

abitmore commented 2 years ago

Fixed by bitshares/bitshares-fc#243 and #2579.