Skip to content

btc: G0/G1 bake golden share-format fixture + parity KAT - #392

Merged
frstrtr merged 2 commits into
masterfrom
btc/g01-bake-golden-parity-kat
Jun 24, 2026
Merged

btc: G0/G1 bake golden share-format fixture + parity KAT#392
frstrtr merged 2 commits into
masterfrom
btc/g01-bake-golden-parity-kat

Conversation

@frstrtr

@frstrtr frstrtr commented Jun 23, 2026

Copy link
Copy Markdown
Owner

G0/G1 — bake the BTC share-format baseline + parity KAT

Now that the BTC fork pin is resolved to p2pool-btc-jtoomim @ ece15b03fc23, this bakes the share-format golden fixture and adds the KAT that fires G0/G1 byte-parity.

What

  • Golden fixture tools/conformance/fixtures/btc.g01.golden.json — emitted by the existing tools/conformance/extract_share_format.py (static extraction, no execution of the py2 baseline) against the pinned jtoomim tree. -f added (tools/ is gitignored).
  • KAT src/impl/btc/test/g01_share_format_parity_test.cpp — asserts the c2pool btc::PoolConfig constants against the baked golden.

Bucket discipline (operator 3-bucket rule)

  • Isolation primitives IDENTIFIER / PREFIX / P2P_PORT / SEGWIT(33) — asserted byte-equal (must match the live sharechain/peers).
  • MINIMUM_PROTOCOL_VERSION — c2pool floor 3500 >= baseline 3301: an intentional, forward-compatible floor raise (admits jtoomim-master/SPB, excludes forrestv-era v17/v32). Asserted >=, not ==.
  • share-versions — c2pool is additive-v36 over baseline [0..35]; the v36 activation boundary is pinned separately by BTC_version_gate.V36ActivationBoundary. Not re-asserted here.

Fence / CI

Evidence

  • btc_share_test 14/14 green (3 new BTC_g01_share_format cases).
  • Fixture re-emit compare: MATCH 9/9 constants.
  • Commit eb5a61f2, GPG signed (signed=G).

Held for operator tap — I do not self-merge.

frstrtr added 2 commits June 24, 2026 00:02
Bake the BTC share-format baseline now that the fork pin is resolved to
p2pool-btc-jtoomim @ ece15b03fc23. Emit the golden fixture via
tools/conformance/extract_share_format.py (static extraction) and add a
gtest KAT that asserts the c2pool BTC port against it.

Bucket discipline (3-bucket rule):
 - Isolation primitives (IDENTIFIER/PREFIX/P2P_PORT/SEGWIT=33): byte-equal.
 - MINIMUM_PROTOCOL_VERSION: c2pool floor (3500) >= baseline (3301), an
   intentional forward-compatible raise, not a parity break.
 - share-versions additive-v36: boundary pinned by BTC_version_gate KAT.

Rides the existing allowlisted btc_share_test exe (no new target, no
build.yml change). btc_share_test 14/14 green; fixture re-emit MATCH 9/9.
…ate SSOT)

Strengthen the G0/G1 share-format parity gate so an unsanctioned extra/
shifted share-version fails here, not only in the separate activation-
boundary KAT. c2pool has no p2pool-style version array to compare element-
wise, so the single sanctioned additive over the baseline [0,17,32,33,34,35]
is locked against core::version_gate::V36_ACTIVATION_VERSION (==36) plus an
exact-boundary check (36 active, 35 not). Baseline set transcribed from
btc.g01.golden.json @ ece15b03fc23. Test-only, fenced to src/impl/btc/test.
@frstrtr
frstrtr force-pushed the btc/g01-bake-golden-parity-kat branch from b663735 to 15fb06b Compare June 24, 2026 00:02
@frstrtr
frstrtr merged commit 2b1ac2b into master Jun 24, 2026
21 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.

1 participant