Skip to content

feat(dataset): admit 363731, the first block of the July 2015 fork - #8

Merged
deadmanoz merged 1 commit into
mainfrom
363731-bip66
Sep 21, 2026
Merged

deadmanoz merged 1 commit into
mainfrom
363731-bip66

Conversation

@deadmanoz

@deadmanoz deadmanoz commented Sep 21, 2026

Copy link
Copy Markdown
Collaborator

Summary

Block 363731 is a version-2 header mined six blocks after BIP66 made version 3 mandatory at 363725, so Core rejects it with bad-version. It is the block that started the 4 July 2015 fork: the fixture's other five headers, all version 3, chain from it through 363736 before the network reorganized away from them, and the SPV-mining alert followed. Those five descendants fail by ancestry only and are not recorded. This adds the one record under the existing bip66_block_version_below_3 rule; no validator change is needed.

The 80-byte header comes from a blockchain.info block dump that survives in a BTC Relay test fixture alongside the fork's six raw headers, with an independent copy of the same field set in a TypeScript port. Two checks tie the dump to the header. Its 99 transaction IDs, in the dump's order, reproduce the header's merkle root. Its coinbase fields (scriptSig, sequence, output value and script, version, locktime) reserialize to a transaction whose ID is the first of those 99, so the recorded coinbase_scriptsig_hex is authenticated to the header rather than copied from a page. The scriptSig's BIP34 push decodes to 363731, and the parent is canonical 363730, whose nBits 1816418e the record carries as expected_nbits.

The coinbase pays 1BwZeHJo7b7M2op7VDfYnsmcpXsUYEcVHm, which mining-pools lists for BTC Nuggets; the scriptSig itself carries only /P2SH/ and /stratumPool/. The record therefore uses pool_basis: address, the field #7 added. The single observation is a scrape from blockchain.com with the pinned fixture as provenance; a second copy of the same field set in another BTC Relay port is not an independent observer and is not recorded. A short incident note in docs/notes.md records the fork, the provenance chain and the March 2017 bitcoin-dev message that lists this hash among bad-version(0x00000002) rejections.

Testing

python -m unittest discover -s ci -p 'test_*.py' passes all 32 tests, and offline python ci/sanity-check.py reports 48 blocks, 48 contexts, 191 observations and 6 block files. The header was re-decoded from the fixture's 6headers.bin (offset 0) with python-bitcoinlib: hash 0000000000000000009cc829aa25b40b2cd4eb83dd498c12ad0d26d90c439d99, version 2, nTime 1435975780, nBits 1816418e, and the local fixture bytes match GitHub blob bc8ae992 at the pinned commit. mempool.space reports 000000000000000006a320d752b46b532ec0f3f815c5dae467aff5715a6e579e at height 363730 with the same nBits. The merkle-root and coinbase re-derivations above were run against the pinned JSON (233,406 bytes).

Related

The fork is documented on the Bitcoin wiki's July 2015 chain forks page, which lists the six block hashes and attributes 363731 to BTC Nuggets, and in the 4 July 2015 SPV-mining alert. A 16 March 2017 bitcoin-dev message lists this hash among blocks a node rejected with bad-version(0x00000002), alongside the hashes of 363726 and 363967 already in the dataset.

A version-2 header six blocks after BIP66 enforcement, rejected with
bad-version. The header comes from a blockchain.info dump preserved as a
BTC Relay test fixture; its 99 txids reproduce the merkle root and its
coinbase fields reserialise to the authenticated coinbase txid, which ties
the recorded scriptSig to the header. The payout address is listed for
BTC Nuggets in mining-pools, so the pool is attributed by address.
@deadmanoz
deadmanoz merged commit a718958 into main Sep 21, 2026
1 check passed
@deadmanoz
deadmanoz deleted the 363731-bip66 branch September 21, 2026 06:09
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