Skip to content

Fix mixed SegWit/Taproot block fixture and un-ignore test - #16

Merged
secsovereign merged 1 commit into
mainfrom
fix/mixed-block-segwit-taproot-fixture
Sep 21, 2026
Merged

secsovereign merged 1 commit into
mainfrom
fix/mixed-block-segwit-taproot-fixture

Conversation

@secsovereign

Copy link
Copy Markdown
Member

Summary

  • The ignored test_mixed_block_segwit_and_taproot failed is_segwit_transaction because the SegWit output script_pubkey was only OP_0, PUSH_20_BYTES (2 bytes).
  • Real P2WPKH is 22 bytes: OP_0 + push-20 + a 20-byte program (mirrored from src/segwit.rs::test_is_segwit_transaction).
  • Dropped #[ignore] and rewrote the comment — this test never connects a block, so the “pending witness/merkle” claim was wrong; no merkle/witness-commitment work invented.

Test plan

  • cargo fmt / cargo fmt --check
  • CARGO_INCREMENTAL=0 cargo check (path-patch aside during CI-shaped run, restored after)
  • cargo test --test engineering_suite engineering::bip_interaction_tests::test_mixed_block_segwit_and_taproot -- --exact (passes without --ignored)

Stays completely off PR #15 / fix/bip113-mtp-cltv-validation-logic. No PARTIAL_BASELINE bump, no merge/publish.

P2WPKH scriptPubKey was only OP_0 + PUSH_20 (2 bytes); is_segwit_transaction
needs the full 20-byte program (22 bytes total). Mirror src/segwit.rs and
drop the ignore that incorrectly claimed pending merkle/witness work.
@secsovereign
secsovereign merged commit 0ce71b9 into main Sep 21, 2026
11 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