Skip to content

feat(health-check): probe Bitcoin by genesis hash and a recent transaction - #3963

Draft
haiyuechen-nearone wants to merge 1 commit into
3764-foreign-chain-health-hybrid-evmfrom
3764-foreign-chain-health-hybrid-bitcoin
Draft

feat(health-check): probe Bitcoin by genesis hash and a recent transaction#3963
haiyuechen-nearone wants to merge 1 commit into
3764-foreign-chain-health-hybrid-evmfrom
3764-foreign-chain-health-hybrid-bitcoin

Conversation

@haiyuechen-nearone

@haiyuechen-nearone haiyuechen-nearone commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Part of #3764; rationale: #3969. Stacked on #3962, merge bottom-up:

  1. feat: probe Starknet by chain id and a recent transaction #3932 — Starknet: chain id + a recent L1-accepted tx
  2. feat(health-check): probe EVM chains by chain id and a recent finalized transaction #3962 — 6 EVM chains: eth_chainId + a recent finalized tx
  3. feat(health-check): probe Bitcoin by genesis hash and a recent transaction #3963 (this PR) — Bitcoin: genesis hash + a recent tx
  4. feat(health-check): probe Aptos by ledger chain id and a recent transaction #3964 — Aptos: ledger chain id + a recent tx

Replaces Bitcoin's pinned golden tx with the identity probe: verify the genesis block hash (getblockhash 0, never pruned), then inspect the coinbase of a block 10 below the tip. Tip height comes from getbestblockhash + getblock — some edges serve getblockcount as a JSON-RPC 1.0 response the 2.0 transport rejects.

Expected genesis comes from config, no built-ins.

@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-evm branch from 79ee813 to 3a83749 Compare July 24, 2026 12:32
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-bitcoin branch from dfe9f22 to 2812e3a Compare July 24, 2026 12:32
@haiyuechen-nearone haiyuechen-nearone changed the title feat(health-check): Bitcoin genesis-hash + dynamic-tx probe (Option B prototype) feat(health-check): probe Bitcoin by genesis hash and a recent transaction Jul 24, 2026
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-evm branch from 3a83749 to f9b5906 Compare July 24, 2026 14:23
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-bitcoin branch 2 times, most recently from 4cdf6cd to 1e88265 Compare July 27, 2026 10:31
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-evm branch from f9b5906 to f3da245 Compare July 27, 2026 10:31
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-bitcoin branch from 1e88265 to 3d15686 Compare July 27, 2026 11:02
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-evm branch from f3da245 to 798424c Compare July 27, 2026 11:02
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-bitcoin branch from 3d15686 to 95249bb Compare July 27, 2026 11:19
@haiyuechen-nearone
haiyuechen-nearone force-pushed the 3764-foreign-chain-health-hybrid-evm branch from 798424c to 2cbd463 Compare July 27, 2026 11:19
…ction

Extend the identity-based probe to Bitcoin: verify the genesis block hash
(getblockhash 0 — never pruned, and a proof-of-data identity since the provider
must actually hold block 0) against the configured expected identity, then run
the inspector over the coinbase of a block 10 below the tip.

Tip height comes from getbestblockhash + getblock rather than getblockcount:
some provider edges serve getblockcount as a JSON-RPC 1.0-style response the 2.0
transport rejects. The pinned Bitcoin golden vectors are deleted; the expected
genesis comes from configuration like the other identity chains.
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