Skip to content

Migrate Ironwood to the official librustzcash RC (+ merge upstream)#2

Merged
emersonian merged 1 commit into
ironwood-valarfrom
claude/zebra-ironwood-rc-support-l19x33
Jul 4, 2026
Merged

Migrate Ironwood to the official librustzcash RC (+ merge upstream)#2
emersonian merged 1 commit into
ironwood-valarfrom
claude/zebra-ironwood-rc-support-l19x33

Conversation

@emersonian

Copy link
Copy Markdown

Draft. Moves the Ironwood work off the Valar Group librustzcash fork and onto the official librustzcash Ironwood release candidate, and folds in the latest upstream zcash/zcash-devtool.

Supersedes c85bcb4 ("Supply NU6.3 activation heights for testnet/mainnet")

That commit hand-added a testnet NU6.3 override (4_134_000) because the fork's zcash_protocol returned None for NU6.3 on the production networks. The official RC ships that testnet height natively, so the override — and the whole src/network.rs wrapper it lived in — is removed. The tool now uses upstream's data::Network, which implements Parameters directly. (Confirmed: derivation/sync treat Ironwood as active on testnet with no override.)

Dependencies

  • [patch.crates-io]zcash/librustzcash rev 4b13be3c (the commit the zcash_*-*-pre.* RC tags point to), replacing valargroup/librustzcash.
  • Bumped to RC versions: zcash_primitives/zcash_proofs 0.29.0-pre.0, zcash_keys 0.15.0-pre.0, zcash_protocol 0.10.0-pre.0, zcash_transparent 0.9.0-pre.0, zcash_address 0.13.0-pre.0.
  • orchard pinned to =0.15.0-pre.1 from crates.io (the RC uses it directly); the orchard git patch is dropped. halo2 unchanged.

No more cfg gate

Ironwood is the stable Nu6_3 upgrade in the RC (→ V6 transactions), so it builds on a plain cargo build:

  • Removed .cargo/config.toml (no more --cfg zcash_unstable="nu6.3").
  • Added the now-ungated nu6_3 key to the regtest ActivationHeights schema and the inspect UFVK construction.

RC API adaptations

  • Pczt::serialize() now returns Result — handled at every call site.
  • propose_send_max_transfer dropped proposed_version; SendMaxErrorT uses BalanceError (ProposeSendMaxErrT).
  • pay-manual's Orchard BundleView is a (BundleVersion, inputs, outputs) tuple.

Removed wallet migrate-to-ironwood

It wrapped create_orchard_to_ironwood_transaction, which exists only in the Valar fork; the official RC has no equivalent (its wallet still builds V6 transactions with ironwood_anchor: None). Everything else Ironwood-related stays: V6 build/inspect, PCZT Ironwood proofs, and V6 emission via the standard send path once a chain is ≥ NU6.3. Easy to reinstate when an upstream helper lands.

Upstream merge

Includes upstream zcash/zcash-devtool main: configurable regtest --activation-heights (persisted per wallet), non-interactive init, wallet get-info, restore-mnemonic, ZecRocks testnet servers, and more.

Network activation

Network NU6.3 (Ironwood) Status
mainnet not yet scheduled (None) works automatically once upstream assigns a height
testnet 4_134_000 (from zcash_protocol) works today
regtest operator-chosen via --activation-heights (nu6_3 key) active from any height you set

Docs

doc/ironwood.md rewritten for the RC: activation model, step-by-step regtest usage, the cross-component height invariant, and the official Zebra v6.0.0-rc.0 companion (confirm exact node/indexer tags against the current RC before a run).

Verification

  • cargo build (default and --features regtest_support)
  • cargo test --features regtest_support (3/3, incl. regtest activation-height round-trip)
  • cargo clippy --all-targets --features regtest_support -- -D warnings (clean)
  • Runtime: address derivation exercised on regtest/testnet/mainnet.

🤖 Generated with Claude Code

https://claude.ai/code/session_0111k1fGXyi6JrGG3WwbBz5b


Generated by Claude Code

Rebuild the Ironwood work on top of the official librustzcash Ironwood
release candidate instead of the Valar Group fork, and fold in the latest
upstream zcash/zcash-devtool (regtest activation-heights support,
non-interactive init, get-info, restore-mnemonic, ZecRocks testnet, etc.).

This supersedes "Supply NU6.3 activation heights for testnet/mainnet"
(c85bcb4): that commit hand-added a testnet NU6.3 override (4_134_000)
because the fork's zcash_protocol returned None on the production networks.
The official RC ships that testnet height natively, so the override — and the
whole src/network.rs wrapper it lived in — is removed; the tool uses upstream's
data::Network (which implements Parameters directly).

Dependencies:
- [patch.crates-io] targets zcash/librustzcash rev 4b13be3c (the commit the
  zcash_*-*-pre.* RC tags point to) instead of valargroup/librustzcash.
- Direct deps bumped to the RC versions: zcash_primitives/zcash_proofs
  0.29.0-pre.0, zcash_keys 0.15.0-pre.0, zcash_protocol 0.10.0-pre.0,
  zcash_transparent 0.9.0-pre.0, zcash_address 0.13.0-pre.0.
- orchard pinned to =0.15.0-pre.1 from crates.io (the RC uses it directly),
  dropping the orchard git patch.

Ironwood is the stable Nu6_3 upgrade in the RC (V6 transactions), needing no
cfg gate:
- Remove .cargo/config.toml (no more --cfg zcash_unstable="nu6.3").
- Add the now-ungated nu6_3 key to the regtest ActivationHeights schema and
  the inspect UFVK construction.

RC API updates:
- Pczt::serialize() now returns Result; handled at every call site.
- propose_send_max_transfer dropped proposed_version; SendMaxErrorT uses
  BalanceError (ProposeSendMaxErrT).
- pay-manual's Orchard BundleView is a (BundleVersion, inputs, outputs) tuple.

Remove the wallet migrate-to-ironwood command: it wrapped
create_orchard_to_ironwood_transaction, which exists only in the Valar fork
(the RC's wallet builds V6 transactions with ironwood_anchor: None).

Rewrite doc/ironwood.md for the RC: activation model (mainnet/testnet/regtest),
regtest --activation-heights usage, and the official Zebra v6.0.0-rc.0
companion.

Verified: cargo build (default and regtest_support), cargo test
(regtest_support), and cargo clippy --all-targets --features regtest_support
-- -D warnings all pass; address derivation exercised on regtest/testnet/
mainnet.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

Claude-Session: https://claude.ai/code/session_0111k1fGXyi6JrGG3WwbBz5b
@emersonian
emersonian marked this pull request as ready for review July 4, 2026 18:58
@emersonian
emersonian force-pushed the claude/zebra-ironwood-rc-support-l19x33 branch from ac6c90b to f5a6d45 Compare July 4, 2026 18:58
@emersonian
emersonian merged commit 9c7fc73 into ironwood-valar Jul 4, 2026
18 checks passed
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