Skip to content

Instantly share code, notes, and snippets.

@bluespore
Last active July 2, 2026 06:11
Show Gist options
  • Select an option

  • Save bluespore/def5f05eddfacf8db502e60d0944f8e0 to your computer and use it in GitHub Desktop.

Select an option

Save bluespore/def5f05eddfacf8db502e60d0944f8e0 to your computer and use it in GitHub Desktop.
Transfer screen ErrorBoundary repro & regression test scenarios

Transfer screen — ErrorBoundary repro scenarios

Shared test checklist for investigating the Transfer tab crash (An unexpected error occurred. Try again).

Context: A typed amount committed before both source and destination are selected may not have been written to the transfer store (only local input state + a pending ref). A later unsigned-tx hydrate or edit can desync the controlled input and hit the root ErrorBoundary. PR #801 addresses this with optimistic store updates.

What counts as a hit: Root ErrorBoundary UI (not a toast, not LogBox-only in dev). In staging/production, check Sentry for ErrorBoundary events.

Noise (usually not the bug): [RemoteTextInput] ... perform input operation requires a valid sessionID — common iOS simulator keyboard log; does not by itself mean ErrorBoundary.


Primary scenario (from QA)

Start from an account with a balance.

  1. Accounts screen → tap an account

  2. Tap Transfer

  3. Enter a value on the source card → blur (tap away / done on keyboard)

  4. Tap Select destination

  5. Pick a destination account (or contact / address)

  6. After returning to Transfer, do one of:

    # Action Notes
    A Edit source value again Change amount, blur
    B Edit destination value Enter amount on destination card, blur
    C Tap Network fee paid by toggle (swapper) Only visible once fee row shows (destination + positive fee)

Pass: No ErrorBoundary; amounts stay consistent; swipe-to-transfer appears when both sides have valid amounts.

Fail: ErrorBoundary or frozen / wrong amounts on either card.


High-signal variants (easy to miss)

1. Second edit before destination is selected

Often more aggressive than the primary path because the store never gets API-hydrated before the second edit.

  1. Transfer → source selected, no destination
  2. Enter source amount → blur
  3. Without picking destination: edit source again (different value) → blur

Watch for: ErrorBoundary, value jumping to 0 or a stale number, clear button appearing incorrectly.


2. Edit during in-flight unsigned-tx build (timing / race)

Widens the window where loading shimmer replaces the input and store props update mid-interaction.

  1. Enter source amount → blur (no destination)
  2. Pick destination → immediately (while shimmer/loading on a card) edit source or destination

Tip for repro: Use staging API or network throttling so createUnsignedDogecoinTransaction is slow; local haystack is often too fast.


3. Destination amount first (placeholder path)

Only applies if destination card is still “Select destination” — you cannot edit destination until a destination exists. Skip unless testing QR/URL prefill below.


4. Clear after partial entry

  1. Source amount entered, destination not selected (or both selected with amounts)
  2. Tap Clear
  3. Re-enter amounts in different order (source first vs destination first)

Pass: Form and store reset cleanly; no stale swipe-to-transfer.


5. Source account switch mid-flow

  1. Enter amounts with source A + destination
  2. Tap source card → select source B
  3. Edit amounts again

Watch for: ErrorBoundary, clamping to wrong balance, loading stuck.


6. Refund flow (if enabled)

  1. Navigate to Transfer with refund params (transferType=refund, etc.)
  2. Enter / prefilled refund amount before destination resolved
  3. Select destination → edit values or toggle fee (refund may lock payer to “You”)

Network fee toggle (scenario C) — prerequisites

The fee row only renders when:

  • A destination account is selected
  • networkFee > 0 (after unsigned tx or fee preflight)
  • Not in refund-without-destination fallback UI

If the row is hidden, scenario C is N/A — use A or B instead.


Quick regression after fix (PR #801)

After deploying the fix branch:

  • Primary scenario A, B, C — no ErrorBoundary
  • Variant 1 — source edited twice before destination — store shows typed value (not stuck at 0)
  • Variant 2 — edit during loading — no crash (UX may still feel rough; file separately)
  • Pending amount still builds unsigned tx once destination is selected

Comments are disabled for this gist.