{"record":{"id":"e3505910c95ebff4","repo":"linera-io/linera-protocol","slug":"block-receipts-not-found-for-block-block-hash","errorCode":null,"errorMessage":"block receipts not found for block {block_hash}","messagePattern":"block receipts not found for block (.+?)","errorType":"exception","errorClass":"ProofError","httpStatus":null,"severity":"warning","filePath":"linera-bridge/src/proof/gen.rs","lineNumber":142,"sourceCode":"        block.header.inner.encode(&mut block_header_rlp);\n\n        // Sanity check: header RLP hashes to the expected block hash\n        let computed_hash = alloy_primitives::keccak256(&block_header_rlp);\n        if computed_hash != block_hash {\n            return Err(ProofError::Permanent(anyhow::anyhow!(\n                \"header RLP hash mismatch: computed {computed_hash}, expected {block_hash}. \\\n                 This may indicate the RPC returned non-standard header fields.\"\n            )));\n        }\n\n        // 3. Get all block receipts\n        let all_receipts = self\n            .provider\n            .get_block_receipts(block.header.number.into())\n            .await\n            .map_err(|e| ProofError::Transient(e.into()))?\n            .ok_or_else(|| {\n                ProofError::Transient(anyhow::anyhow!(\n                    \"block receipts not found for block {block_hash}\"\n                ))\n            })?;\n\n        // 4. Encode each receipt to canonical EIP-2718 form (as stored in the trie).\n        //    Convert RPC logs → primitives logs so Encodable2718 is available.\n        //    OpReceiptEnvelope handles both standard types and OP deposit (0x7e).\n        let canonical_receipts: Vec<(u64, Vec<u8>)> = all_receipts\n            .into_iter()\n            .enumerate()\n            .map(|(idx, r)| {\n                let consensus_receipt = r.inner.inner.map_logs(|log| log.inner);\n                let encoded = consensus_receipt.encoded_2718();\n                (idx as u64, encoded)\n            })\n            .collect();\n\n        // 5. Build receipt trie and generate proof","sourceCodeStart":124,"sourceCodeEnd":160,"githubUrl":"https://github.com/linera-io/linera-protocol/blob/6c226ddcb332ef55118dc8d0aafbd093d5420899/linera-bridge/src/proof/gen.rs#L124-L160","documentation":"eth_getBlockReceipts(block_number) returned null. Classified ProofError::Transient. The endpoint either cannot serve receipts for that block (pruned history) or does not fully support the method for it. The proof pipeline needs all receipts of the block to rebuild the receipts trie, so it aborts.","triggerScenarios":"Calling generate_deposit_proof for an old block on a node with pruned receipt history; providers that gate or partially implement eth_getBlockReceipts; racing the node indexer right after a block is produced.","commonSituations":"Free-tier RPC plans with history limits; batch proof generation for historical deposits; some self-hosted nodes started without archive flags.","solutions":["Use an archive node or full-history provider","Retry shortly after block production to rule out indexer lag","Confirm the provider supports eth_getBlockReceipts by querying the block number directly"],"exampleFix":null,"handlingStrategy":"retry","validationCode":"// Preflight: confirm eth_getBlockReceipts is servable for the block.\nlet block = provider.get_block_by_hash(bh).await?.expect(\"block\");\nif provider.get_block_receipts(block.header.number.into()).await.ok().flatten().is_none() {\n    // provider cannot serve receipts: use an archive RPC\n}","typeGuard":null,"tryCatchPattern":"Err(ProofError::Transient(e)) if e.to_string().contains(\"block receipts not found\") => {\n    // short backoff first (indexer lag), then fall back to an archive provider\n}","preventionTips":["Verify the provider implements eth_getBlockReceipts during onboarding","Use archive nodes for proof generation workloads","Retry shortly after block production before assuming pruning"],"tags":["evm","rpc","receipts","pruned-node","bridge","transient"],"backgroundTag":"pruned-block-history","analyzedSha":"6c226ddcb332ef55118dc8d0aafbd093d5420899","analyzedAt":"2026-08-22T22:49:09.787Z","schemaVersion":2},"datasetVersion":"2026-08-23T01:17:44.959Z"}