Add zingo consensus#275
Merged
Merged
Conversation
New zero-dependency workspace member holding ActivationHeights, ActivationHeightsBuilder, and NetworkType, ported from zingo_common_components 0.4.0 (nu6.3 included). BlockHeight, TxId, and H0 are not ported: an org-wide audit found zero consumers. The all-heights-one regtest schedule is the documented Default impl, replacing the old for_test::all_height_one_nus helper. zcash_local_net and regtest-launcher consume it by path, and the prelude re-export gains ActivationHeightsBuilder so consumers can construct the type without a direct dependency. Phase 1 of the zingo-common disintegration plan. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Crates that depend on zcash_local_net must not also directly depend on zingo-consensus. The vocabulary reaches them through the zcash_local_net::protocol re-exports. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Zaino dev pins the add_client_support lineage (#269), so the zingo-consensus migration must contain it before zaino can bump its pin. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
dannywillems
approved these changes
Jul 2, 2026
dannywillems
left a comment
Contributor
There was a problem hiding this comment.
utACK 0a003b4.
However, I see the following deps used in Cargo.toml:
#zcash
zcash_protocol = { version = "0.9.0", features = ["local-consensus"] }
# zebra
zebra-chain = "9.0.0"
zebra-node-services = "7.0.0"
zebra-rpc = "9.0.0"
Are they not already defining the structures for the network type and activation heights? If yes, it would be easier to maintain the whole Z3 stack if we avoid duplication.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
anyhow 1.0.102 -> 1.0.103 for RUSTSEC-2026-0190 (unsound Error::downcast_mut). Ignore RUSTSEC-2026-0173 (proc-macro-error2 unmaintained): it arrives via getset, which orchard 0.14 pins inside the zebra-rpc chain, so no local change removes it. The direct getset dependency is slated for elimination in a follow-up PR regardless. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The workflow pins nightly-2025-10-18 (rustdoc JSON format 56) but installed the tool unpinned. 0.5.0 (released 2026-06-08) requires format 57, which has failed the External Types job on every PR since. 0.4.0 is the version the last green run used. Bump the tool and PINNED_NIGHTLY together in a future maintenance PR. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The zcash-devtool binary is not provisioned in the CI runner image, so the five devtool_client integration tests (from add_client_support) have never passed in CI. The zcash_devtool JSON-parsing unit tests still run. Re-enable when test.yaml installs the binary. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Member
Author
|
Good questions, to be continued... |
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.
What
zingo-consensusholdingActivationHeights,ActivationHeightsBuilder, andNetworkType, ported fromzingo_common_components0.4.0 (nu6.3 included).BlockHeight,TxId, andH0are not ported: an org-wide audit found zero consumers.Defaultimpl, replacing the oldfor_test::all_height_one_nushelper.zcash_local_netconsumes it by path and re-exports the builder alongside the two types it already re-exported, so consumers can construct the type without a direct dependency.regtest-launcherconsumes thezcash_local_net::protocolre-exports and holds no direct dep, per the dependency rule below.add_client_supporton dev, this branch merges dev and the diff is purely the zingo-consensus work. The client code's fivezingo_common_componentsreferences are swapped tozingo-consensus. Note for the zaino side: zaino'sdrop_zingo_common_componentsbranch currently pins0a003b4on this branch; after this merges, that pin should move to the merge commit or the release tag.Why
Phase 1 of the zingo-common disintegration (see
docs/DISINTEGRATION.mdin zingolabs/zingo-common). Every network upgrade currently walks a four-repo publish cascade through zingo-common. Co-locating the vocabulary with its main consumer removes one hop, and the leaf-crate shape keeps wallet builds free of the harness: zingolib pulls only this crate, behind its default-offregtestfeature (zingolib ADR 0002).Dependency rule: a crate that depends on
zcash_local_nettakes the vocabulary through itsprotocolre-exports and must not also directly depend onzingo-consensus. The only direct dependents arezcash_local_netitself and zingolib's optionalregtestfeature.Verification
cargo check --workspace --all-features,cargo clippy --workspace --all-features, andcargo fmt --all -- --checkare clean.cargo nextest run -p zingo-consensuspasses 5/5.After merge
Tag and publish
zingo-consensusto crates.io, then flip the git pins in zingolib (add_regtest_gate) and zaino (drop_zingo_common_components) to the tag.🤖 Generated with Claude Code