Admit 1Hash block 474294 under a new omitted-parent-transaction rule - #5
Draft
deadmanoz wants to merge 3 commits into
Draft
Admit 1Hash block 474294 under a new omitted-parent-transaction rule#5deadmanoz wants to merge 3 commits into
deadmanoz wants to merge 3 commits into
Conversation
deadmanoz
marked this pull request as draft
September 11, 2026 08:39
deadmanoz
force-pushed
the
missing-unconfirmed-parent
branch
from
September 11, 2026 08:40
ad2790c to
c7d24f5
Compare
Collaborator
Author
|
Drafting because I need to update the observation source in merge-mining-research so that the JSON entry has the correct "final" link (it needs to be demoted in that dataset to an error block) |
The in-block forward-spend checker cannot see a parent that confirmed only in a competing same-height block. Add that evidence rule and the 1Hash body so ConnectBlock's missing-or-spent failure is re-derivable.
…loader Keep two confirmation requests in flight and stop once a proving parent transaction is found. Name the shared predicate confirmed_at_or_after, since it accepts the candidate height itself.
Move the parent_kind and coinbase height checks into the context rules, alongside the other required fields, and require coinbase_scriptsig_hex so the height is bound to the body. The validator only compares the parent_kind string; whether the previous block really is canonical is left to review, and the schema now says so.
deadmanoz
force-pushed
the
missing-unconfirmed-parent
branch
from
September 11, 2026 08:51
c7d24f5 to
8e70c0b
Compare
deadmanoz
added a commit
to deadmanoz/stale-blocks
that referenced
this pull request
Sep 11, 2026
1Hash block 00000000000000000182acdf5657c93a0769dc6f9004047496b2e15efc6a4232 spends an output whose parent transaction confirmed only in the same-height competitor. That is bad-txns-inputs-missingorspent at connect time, not an in-block ordering error. The replacement record and binary are in bitcoin-data/invalid-blocks#5. Point the README at the companion repository rather than the pre-474294 tree snapshot.
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.
Adds a
missing_unconfirmed_parentevidence rule and the first block it admits: height 474294,00000000000000000182acdf5657c93a0769dc6f9004047496b2e15efc6a4232, mined by 1Hash in July 2017.Transaction 110 spends
b11a78c6c61af1cb37586f639050d74b95c2b0fd525623b6cb6a4bb4fba46a0e:1. That parent transaction is not in the body and did not exist at the tip of 474293, soConnectBlockfails withbad-txns-inputs-missingorspent. Both transactions confirmed in the same-height competitor000000000000000000db2504327e272fe7658fac0dd0741f46b212256e500886.The existing
bad-txns-inputs-missingorspentchecker (477115, 809478) only recognises in-block forward spends. 474294 has none, and a prevout absent from the body is what every valid block looks like, so absence alone cannot be the evidence.What CI checks
CI accepts a
missing_unconfirmed_parentrecord into the dataset only with a complete body,parent_kindcanonicaland coinbase context matching the record; an input whose parent transaction is not in the block; that transaction fetched or cached and verified by txid, containing the spent output; and Esplora/tx/{txid}/statuscurrently reporting it confirmed in a different block at this height or later. Unconfirmed or 404 replies are not evidence and are not cached; a parent confirmed below this height is a normal spend.CI does not rebuild the UTXO set at 474293 or replay
ConnectBlock. It reasons from where the parent transaction is confirmed today: at or above the candidate's height means it was not in the chain below it, so its output did not exist when the block was mined. Two limits follow. A parent that confirmed earlier, was reorged out and re-confirmed at or above the candidate's height would pass, because the check sees only where the parent is confirmed now, not whether its output existed at the time. And the inference assumes the candidate extends the main chain. CI requiresparent_kindto becanonicalbut does not verify that the previous block is on the main chain; that is established by review. Both are documented indocs/schema.md.Changes
ci/block_evidence.py,ci/prevouts.py,ci/sanity-check.py: predicate, shared raw-tx and/statusfetch with{txid}.status.jsoncaching,RULESentry requiringparent_kind,coinbase_height,coinbase_scriptsig_hex.data/invalid-blocks.jsonlandblocks/474294-…4232.bin(byte-identical to bitcoin-data/stale-blocks2633e0e). Observations: merge-mining-research Namecoin child 349887 and the chainquery.com orphan listing in NStifter/mergedmonitor.parent_kindandparent_mtpalready use "parent" that way./statusdecoding, corrupt cache files and admission failure without cached confirmation.Verification
python ci/sanity-check.py --fetch-prevouts(47 blocks, 6 block files) andpython -m unittest discover -s ci -p 'test_*.py'(31 tests).Related
bitcoin-data/stale-blocks#139 removes the invalid block from stale-blocks.
Original discussion: https://bitcointalk.org/index.php?topic=2041607.0.