feat(mobile): add transaction pending state before confirmation (#253) - #345
Merged
El-swaggerito merged 1 commit intoJul 27, 2026
Merged
Conversation
…nvera#253) Add a 'confirming' HandoffPhase and optimistic pending entries in walletStore (keyed by hash) so submitted transactions show a distinct pending state instead of implying success immediately. Extract a shared StatusBadge component and use neutral copy for post-submission failures, since a network error doesn't prove the transaction was rejected. Also fixes remaining RN/Hermes compatibility issues blocking real transaction submission (AbortSignal.timeout, fetch body serialization, Buffer.subarray losing its prototype on Hermes) after picking up upstream's fix for the stellar-sdk module resolution path.
El-swaggerito
marked this pull request as ready for review
July 27, 2026 10:28
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #253
Summary
Adds a distinct pending state for submitted transactions instead of implying success the moment
submitTransaction()resolves.'confirming'phase toHandoffPhase(betweensubmittingandcompleted) so the UI shows "Confirming…" with a Pending badge before the flow completes.walletStore(keyed by transaction hash, not a single slot, so concurrent sends don't clobber each other), reconciled against the next Horizon refresh.StatusBadgecomponent (previously a privateBadgeinsettings.tsx), reused in the review screen, transaction history rows, and settings.payment-success.tsxnow says "Payment Confirmed" instead of the earlier "Payment Sent / submitted successfully" claim.submitTransaction()is synchronous, so there's no genuine post-submit async window to poll. The existing pull-to-refresh on History is the "polling placeholder" per the AC, with a comment marking where a real polling hook would attach.Acceptance criteria
statusfalls back to no badge, not a guess)Compatibility fixes (see note above)
Found while testing the flow end-to-end on an Android emulator — none of these are specific to #253, they block any real transaction submission on the currently-pinned
@stellar/stellar-sdk@16.1.0:AbortSignal.timeoutmissing in Hermes (the SDK's fetch client calls it unguarded)fetchnot serializing aURLSearchParamsbody (Horizon was receiving an empty envelope).subarray()losing theBufferprototype (facebook/hermes#1495), so the transaction envelope was reaching Horizon as raw comma-joined bytes instead of base64All three patched in
shim.js. Two other issues I initially hit (metro.config.js's stale stellar-sdk path,tsconfig.json'smoduleResolution) were already fixed upstream in6623bce— this branch is rebased on that.Test plan
npx jest— 332/332 passing