You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 2, 2022. It is now read-only.
Describe the bug
There appears to be a bug in eos-api.ts where hasRequiredTaposFields returns false if ref_block_num is equal to 0. We noticed a failed transaction where the block number was 61931520. This caused refBlock.block_num & 0xffff in eosjs-serialize.ts to return 0 and then the subsequent transaction failed to get signed.
To Reproduce
Steps to reproduce the behavior:
Generate an unsigned transaction for a block where refBlock.block_num & 0xffff equals zero. This is any block divisible by 65536.
Try to sign the transaction
Watch the signing fail due to hasRequiredTaposFields returning false!
Expected behavior
The transaction is valid when ref_block_num is zero.
Version of EOSJS
Latest
Describe the bug
There appears to be a bug in
eos-api.tswherehasRequiredTaposFieldsreturns false ifref_block_numis equal to 0. We noticed a failed transaction where the block number was 61931520. This causedrefBlock.block_num & 0xffffineosjs-serialize.tsto return 0 and then the subsequent transaction failed to get signed.To Reproduce
Steps to reproduce the behavior:
refBlock.block_num & 0xffffequals zero. This is any block divisible by 65536.hasRequiredTaposFieldsreturning false!Expected behavior
The transaction is valid when
ref_block_numis zero.