Skip to main content

bundle_version_for_branch

Function bundle_version_for_branch 

Source
pub fn bundle_version_for_branch(
    consensus_branch_id: BranchId,
    pool: ValuePool,
) -> Option<BundleVersion>
Expand description

Returns the [BundleVersion] in effect for the given Orchard-protocol value pool under the given consensus branch, or None if the pool is not supported under that branch (the Orchard pool prior to NU5; the Ironwood pool prior to NU6.3).

The protocol revision is determined by [BranchId::orchard_protocol_revision]. The BundleVersion fixes a bundle’s flag-byte grammar, cross-address semantics, and circuit generation:

  • Orchard pool, NU5 through NU6.1: historical insecure circuit, cross-address enabled, proof size not enforced;
  • Orchard pool, NU6.2: fixed circuit, cross-address enabled;
  • Orchard pool, NU6.3 onward: post-NU6.3 circuit, cross-address disabled (consensus-mandated);
  • Ironwood pool, NU6.3 onward: post-NU6.3 circuit, cross-address enabled.