-
Notifications
You must be signed in to change notification settings - Fork 5.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
_checkIfTxWasDropped nextworkNextNonce type correction #8827
Conversation
No radix-16 needed for nonce, already done, and BN doesn't need to be radix, returns number.
Builds ready [efd9c0d]
Page Load Metrics (662 ± 44 ms)
|
I don't understand, why isn't this needed/correct? |
parseInt(0x18, 16) !== parseInt('0x18', 16) edit |
I think the problem here is that This also explains why I wasn't able to reproduce the problem - my transaction count was below 10, so the base-10 and base-16 numbers were equivalent. |
…ify on networkNonce before parseInt.
Co-authored-by: Mark Stacey <markjstacey@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Ah, unit test failures. It looks like the stub was returning a string, when it should have been returning a BN
test/unit/app/controllers/transactions/pending-tx-tracker-test.js
Outdated
Show resolved
Hide resolved
Builds ready [65f8e0e]
Page Load Metrics (734 ± 31 ms)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! (though I do agree that using .toNumber()
is marginally better)
Builds ready [fd435ec]
Page Load Metrics (1165 ± 88 ms)
|
* origin/develop: Fix signing method bugs (#8833) replace icons with Checkbox component (#8830) Use gulp-cli@2.3.0 (#8845) Use node-sass@4.14.1 (#8844) Call getMethodDataAsync when knownMethodData[fourBytePrefix] object is empty (#8836) Update connected status popover content (#8834) Use @metamask/controllers@2.0.1 (#8832) ParseInt nextworkNextNonce correction (#8827) Fix first time onboarding popup position (#8829) fix overflowing contract names and origins (#8823) Hide 'Expand view' button in fullscreen (#8826)
No radix-16 needed for nonce, already done,. NextNetworkNonce BN doesn't need it either, returns number when parsed.Stringify on networkNonce before parseInt.Just remove radix-16 on nextNetworkNonce.Radix-10 on nextworkNextNonce BN.networkNextNonce.toNumber()
Fixes #8688.