-
Notifications
You must be signed in to change notification settings - Fork 149
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
Negative balance due to unprocessable transaction (already processed nonce) #3921
Comments
The workaround is: wait for the pending transaction to get dropped after 256 blocks (approx. 2 days) or use another wallet. I am not sure if this problem always pops up or only when the new transaction isn't propagated through the network before the old one gets picked up by a miner or the other way around (the new one gets picked up without being propagated over the Stacks network to replace (RBF) all other instances with lower fee). |
hm, yeah, I managed to reproduce this problem and my pr actually doesn't solve this. wonder what can we do here 🤔
|
wdyt @314159265359879 @markmhx |
Interesting idea I think it will work in most cases but could set us up for disaster in times of congestion. Using the time it has been pending, anything more than two hours is good indication of an unprocessable/troublesome transaction, if there is no congestion on the network. It could be problematic if there is congestion though... it would lead to more unprocessable/double spend transaction as it gives "false positives" in such a case. I think the following would be safer: |
this will lead to that we will fetch all txs and all pending txs for all accounts in case user, e.g. opens select acc modal. I feel like we need some cheaper solution, or it's ok? @kyranjamie @markmhx |
Ow I see, I didn't realize that. Then you just need all the pending transactions (an account can have 25 max I believe, and an account having that many pending is quite rare). Probably best if @kyranjamie comments on this. |
Spoke with @alter-eggo about this. Suggestion was to not subtract pending txs if nonce value exists in array of mined transactions |
## [4.36.0](v4.35.0...v4.36.0) (2023-07-18) ### Features * change arrow icon in send flow ([2b4a2a9](2b4a2a9)) * change caret color in seed phrase input ([8fc248c](8fc248c)) ### Bug Fixes * add module type ([227ea75](227ea75)) * choose acc total balance, closes [#3989](#3989) ([6e4bedf](6e4bedf)) * disable sentry in service worker ([d5e8f26](d5e8f26)) * entire activity item is clickable ([167429b](167429b)) * exceed amount in rbf, closes [#3921](#3921) ([0d8e72f](0d8e72f)) * form restore ([c48fc22](c48fc22)) * go to RequestDiagnostics after fresh installation to avoid flash redirect, fixes [#2330](#2330) ([bef7e08](bef7e08)) * port disconnecting ([da3a2f5](da3a2f5)) * prevent secret key showing before blurred ([6929ada](6929ada)) * refactor JSX namespace to React.JSX ([4a07bcb](4a07bcb)) * retore form state, chromium ([be3204d](be3204d)) * secret key input, closes [#3954](#3954) ([5f000ba](5f000ba)) * stacks nfts loading key not unique, closes [#3789](#3789) ([dad5d6e](dad5d6e)) * upgrade packages ([74f6d25](74f6d25)) * use routes over state for home tabs, closes [#3518](#3518) ([cb2f317](cb2f317)) * use windows friendly syntax so that yarn dev will launch on windows machines ([56b6778](56b6778)) ### Internal * keychain ([c5d4761](c5d4761)) * migrate to manifest version 3 ([03dbb1e](03dbb1e)) * mv3 fix ([0f54a1f](0f54a1f)) * restore gaia functionality ([bf136dc](bf136dc)) * sending max fees, closes [#3871](#3871) ([90c1c31](90c1c31)) * stacks keychain logic ([846132b](846132b)) * upgrade packages ([d3978f0](d3978f0)) * upgrade packages, p1 ([cb7da02](cb7da02)) * upgrade packages, p2 ([51b7da0](51b7da0))
## [4.36.0](v4.35.0...v4.36.0) (2023-07-18) ### Features * change arrow icon in send flow ([2b4a2a9](2b4a2a9)) * change caret color in seed phrase input ([8fc248c](8fc248c)) ### Bug Fixes * add module type ([227ea75](227ea75)) * choose acc total balance, closes [#3989](#3989) ([6e4bedf](6e4bedf)) * disable sentry in service worker ([d5e8f26](d5e8f26)) * entire activity item is clickable ([167429b](167429b)) * exceed amount in rbf, closes [#3921](#3921) ([0d8e72f](0d8e72f)) * form restore ([c48fc22](c48fc22)) * go to RequestDiagnostics after fresh installation to avoid flash redirect, fixes [#2330](#2330) ([bef7e08](bef7e08)) * port disconnecting ([da3a2f5](da3a2f5)) * prevent secret key showing before blurred ([6929ada](6929ada)) * refactor JSX namespace to React.JSX ([4a07bcb](4a07bcb)) * retore form state, chromium ([be3204d](be3204d)) * secret key input, closes [#3954](#3954) ([5f000ba](5f000ba)) * stacks nfts loading key not unique, closes [#3789](#3789) ([dad5d6e](dad5d6e)) * upgrade packages ([74f6d25](74f6d25)) * use routes over state for home tabs, closes [#3518](#3518) ([cb2f317](cb2f317)) * use windows friendly syntax so that yarn dev will launch on windows machines ([56b6778](56b6778)) ### Internal * keychain ([c5d4761](c5d4761)) * migrate to manifest version 3 ([03dbb1e](03dbb1e)) * mv3 fix ([0f54a1f](0f54a1f)) * restore gaia functionality ([bf136dc](bf136dc)) * sending max fees, closes [#3871](#3871) ([90c1c31](90c1c31)) * stacks keychain logic ([846132b](846132b)) * upgrade packages ([d3978f0](d3978f0)) * upgrade packages, p1 ([cb7da02](cb7da02)) * upgrade packages, p2 ([51b7da0](51b7da0))
## [6.0.0](v5.0.0...v6.0.0) (2023-07-25) ### ⚠ BREAKING CHANGES * this change is sufficient enough to warrant a major bump ### Features * added bitcoin contract request page ([83cf049](83cf049)) * added use-bitcoin-contract hook and additional functions and configs ([626ef0b](626ef0b)) * extended rpcmethods with bitcoin contract related case, added routes and success/failure pages ([f0ff7af](f0ff7af)) * manifest v3 release trigger ([80615ca](80615ca)) ### Bug Fixes * added back dlc-wasm-wallet package ([ba27aaf](ba27aaf)) * added working package.json ([e8067d0](e8067d0)) * cross install tracking ([3bc59ac](3bc59ac)) * fixed frozen lockfile ([536aeec](536aeec)) * made requested css and const changes ([8846e0e](8846e0e)) * modified bitcoin contract request ui (width, size, weight) ([36d7c80](36d7c80)) * modified yarn lock file ([52b1d14](52b1d14)) * multi extension loading ([03465c0](03465c0)) * only show errors when field not in focus, closes [#3766](#3766) ([abffd71](abffd71)) * ran prettier formatting ([16ca959](16ca959)) * ran prettier formatting ([515b1e5](515b1e5)) * remove warning banner ([b3427bf](b3427bf)) * type errors ([a2598a9](a2598a9)) * unprocessable pending txs balance subtraction, closes [#3921](#3921) ([2d284db](2d284db)) ### Internal * **release:** 4.36.0 ([8184b75](8184b75)), closes [#3989](#3989) [#3921](#3921) [#2330](#2330) [#3954](#3954) [#3789](#3789) [#3518](#3518) [#3871](#3871) * **release:** 5.0.0 ([0e73a1e](0e73a1e))
RBF'ed transactions create a clone with the same nonce and a higher fee. The clone can remain pending in the wallet/API because we do not have a special state for it as suggested here: hirosystems/explorer#1038
This is different from negative balance due to incoming transactions and the fees which is described here: #3761
The text was updated successfully, but these errors were encountered: