Skip to content

Zcash: Orchard → Ironwood (NU6.3) migration UX#6077

Draft
peachbits wants to merge 4 commits into
developfrom
matthew/zec-ironwood-migration-gui
Draft

Zcash: Orchard → Ironwood (NU6.3) migration UX#6077
peachbits wants to merge 4 commits into
developfrom
matthew/zec-ironwood-migration-gui

Conversation

@peachbits

@peachbits peachbits commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Zcash Ironwood (NU6.3) v1: migration card → locked max send-to-self

Pairs with react-native-zcash#71 and edge-currency-accountbased#1075 (both v1). Restructured 2026-07-21 to v1-only (scenes/notification/kebab moved to the stacked v2 PR): on login the wallet syncs; when the engine reports a sweep is worthwhile, a card appears on the Zcash wallet scene; tapping it prefills a locked max send-to-self in the ordinary send scene; the card clears via the status poll once Orchard empties by any means. Re-pinned 2026-07-22 to the rebuilt dependency builds (SDK series head 6e29ab42) — notably, upstream's own QA pass (zcash/zcash-swift-wallet-sdk#1817) redesigned their immediate migration into exactly this mechanism: an ordinary send-max sweep.

What's here

  1. Status util + hook — cleaner-validated access to otherMethods.getMigrationStatus + a polling hook safe to call unconditionally. iOS-gated until the Android bridge lands.
  2. The card — recommended-tone copy by design ("Move your Orchard funds to Ironwood… Your funds stay safe and spendable either way"): nothing is framed as "required", because Orchard stays spendable post-fork and drains passively through ordinary spends (the sweep is an accelerator for dormant funds, one clean uncorrelated reveal instead of repeated payment-linked ones). Displays the Orchard-pool balance at risk (ZIP 318 requires the entry point to) from status.remainingOrchardZatoshi, and discloses that the migrated amount becomes public (ZIP 315 consent). Tapping: getAddresses → own unified address → getMaxSpendablesend2 with address/amount/wallet tiles locked (the account-activation locked-send pattern), an info tile, and metadata.notes labeling. The spendInfo carries top-level otherParams.ironwoodMigration: true, which makes the engine quote and build an Orchard-only sweep — so the locked amount is the Orchard balance minus fee, not a whole-wallet max send. Zero SendScene2 changes; fee/amount truth from the engine's makeSpend. hiddenFeaturesMap deliberately omitted (scamWarning: false triggers the modal).
  3. Pins — both tarballs from the ironwood-ffi-6e29ab42 release (v1 builds).

Verification

  • lint + tsc + jest green per commit (5 status-util tests).
  • Release simulator build with the pinned tarballs: BUILD SUCCEEDED, 0 undefined zcash/grpc/NIO symbols with the piratechain consumer co-installed, migration FFI symbols linked; app installs, launches, and renders login cleanly. Card correctly dormant pre-activation on mainnet.

Notes for review

  • The sweep is Orchard-only (the engine drives the SDK's proposeImmediateMigration, an Orchard-scoped send-max), so Sapling and transparent funds are left untouched — matching ZIP 318's "balance at risk" being the Orchard-pool balance specifically.
  • Engine-side dust floor prevents prompting for sweeps that would be mostly fee.
  • The guided flow (options/plan/progress scenes, notification center, kebab) is the stacked v2 PR, held for live validation.

peachbits and others added 4 commits July 21, 2026 12:21
Typed access to the engine's v1 Orchard -> Ironwood detection surface (wallet.otherMethods.getMigrationStatus, cleaner-validated) plus a polling hook safe to call unconditionally from shared scenes. iOS-gated until the Android bridge lands. Strings use a recommended tone by design: the sweep is worthwhile, not mandatory - Orchard stays spendable post-fork and drains passively through ordinary spends, so nothing is framed as "required".

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The Zcash wallet scene's migration card (shown when the engine reports a sweep is worthwhile) prefills the ordinary send scene with the wallet's own unified address and its max spendable amount, with the address/amount/wallet tiles locked - the account-activation locked-send pattern. Post-activation, plain proposals route outputs and change into Ironwood, so this is a normal transaction through the normal pipeline: fee and final amount come from the engine's makeSpend, and the tx is labeled via metadata notes.

Copy is deliberately recommended-tone, not required: Orchard stays spendable post-fork and drains passively through ordinary spends. The card clears via the status poll once Orchard empties by any means (sweep sent, or drained organically). A max send sweeps every shielded pool into Ironwood - the strings say "shielded ZEC", not just Orchard.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
react-native-zcash and edge-currency-accountbased pin to the Edge-hosted Ironwood v1 builds on the ironwood-ffi-2922143e release (release/2.6.0 SDK line; NU6.3 activation heights are set - mainnet 3428143 / testnet 4134000). Tarball URLs and integrities point at builds of the v1 branches of each repo (react-native-zcash zcash-ironwood @ 124ee19, edge-currency-accountbased matthew/zec-ironwood-migration @ 6f579238). Swaps to npm releases when upstream tags the 2.6.0 SDK.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings July 24, 2026 20:00
@peachbits
peachbits force-pushed the matthew/zec-ironwood-migration-gui branch from dae76da to 58a1bb5 Compare July 24, 2026 20:00

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Warning

  • Copilot's review of this pull request may be incomplete because some of the changed files are excluded by your Copilot content exclusion settings. See Excluding content from Copilot for details.

Pull request overview

Adds the first-pass (v1) Zcash Orchard → Ironwood (NU6.3) migration UX: detect when an Orchard-only sweep is worthwhile, surface a recommendation card on the wallet scene, and route the user into a locked “send max to self” flow using the existing SendScene2.

Changes:

  • Introduces a typed migration-status util (cleaners) plus a polling hook to safely query wallet.otherMethods.getMigrationStatus (iOS-gated).
  • Adds a Zcash-only “migration recommended” card to the wallet scene that navigates into send2 with locked address/amount/wallet tiles and an otherParams.ironwoodMigration flag.
  • Adds localized strings + a Jest test suite for the migration util, and updates the changelog (plus dependency pin updates in excluded manifests).

Reviewed changes

Copilot reviewed 6 out of 9 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/util/zcashMigration.ts Typed + validated access to engine migration status, with platform gating and error fallback.
src/hooks/useZcashMigrationStatus.ts Polling hook wrapper around getZcashMigrationStatus for unconditional use in shared UI.
src/components/themed/TransactionListTop.tsx Renders the migration card and wires navigation into a locked SendScene2 send-to-self sweep flow.
src/locales/en_US.ts Adds en_US string entries for the migration card and send info tile.
src/tests/zcashMigration.test.ts Adds tests for the util’s capability gating and cleaner validation.
CHANGELOG.md Notes the new migration card + send-to-self flow and iOS-only gating.
package.json Updated (content excluded by policy).
package-lock.json Updated (content excluded by policy).
src/locales/strings/enUS.json Updated (content excluded by policy).
Files excluded by content exclusion policy (3)
  • package-lock.json
  • package.json
  • src/locales/strings/enUS.json

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/locales/en_US.ts
Comment on lines +775 to +776
zcash_migration_recommended_body_1s:
"Zcash's Ironwood network upgrade added a new shielded pool, and %s of your ZEC is still in the older Orchard pool. We recommend moving it with a single send to yourself. The amount you move will be publicly visible on the blockchain. Your funds stay safe and spendable either way.",
Comment on lines +702 to +706
const unifiedAddress = addresses.find(
address => address.addressType === 'unifiedAddress'
)
if (unifiedAddress == null) return
const spendInfo: EdgeSpendInfo = {
Comment on lines +1 to +5
import { describe, expect, it } from '@jest/globals'
import type { EdgeCurrencyWallet } from 'edge-core-js'

import { getZcashMigrationStatus } from '../util/zcashMigration'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants