{"record":{"id":"e6b010077019a41c","repo":"linera-io/linera-protocol","slug":"missing-certificates-for-chain-chain-id-in-heigh","errorCode":null,"errorMessage":"Missing certificates for chain {chain_id} in heights {heights:?}","messagePattern":"Missing certificates for chain (.+?) in heights (.+?)","errorType":"validation","errorClass":"NodeError","httpStatus":null,"severity":"error","filePath":"linera-core/src/remote_node.rs","lineNumber":275,"sourceCode":"            });\n        }\n\n        for certificate in &certificates {\n            ensure!(\n                certificate.inner().chain_id() == chain_id,\n                NodeError::UnexpectedCertificateValue\n            );\n            if let Some(expected_height) = expected_heights.pop_front() {\n                ensure!(\n                    expected_height == certificate.inner().height(),\n                    NodeError::UnexpectedCertificateValue\n                );\n            } else {\n                return Err(NodeError::UnexpectedCertificateValue);\n            }\n        }\n\n        ensure!(\n            expected_heights.is_empty(),\n            NodeError::MissingCertificatesByHeights {\n                chain_id,\n                heights: expected_heights.into_iter().collect(),\n            }\n        );\n        Ok(certificates)\n    }\n\n    /// Checks that requesting these blobs when trying to handle this certificate is legitimate,\n    /// i.e. that there are no duplicates and the blobs are actually required.\n    pub fn check_blobs_not_found<C: Certified>(\n        &self,\n        certificate: &C,\n        blob_ids: &[BlobId],\n    ) -> Result<(), NodeError> {\n        ensure!(!blob_ids.is_empty(), NodeError::EmptyBlobsNotFound);\n        let required = certificate.value().required_blob_ids();","sourceCodeStart":257,"sourceCodeEnd":293,"githubUrl":"https://github.com/linera-io/linera-protocol/blob/6c226ddcb332ef55118dc8d0aafbd093d5420899/linera-core/src/remote_node.rs#L257-L293","documentation":"Raised at the end of RemoteNode::download_certificates_by_heights when the validator answered without error but returned fewer certificates than the heights requested: the expected_heights queue is not empty after consuming everything returned. Unlike the wrong-value checks, this is usually a lagging or pruned validator that simply does not hold the certificates at those heights anymore (or not yet).","triggerScenarios":"Requesting heights beyond a validator's pruned history; asking a just-started validator for old blocks; requesting heights a validator will only obtain after it syncs from peers; heights for a chain the validator does not track.","commonSituations":"Long-running chains with validator storage pruning; fresh validator replicas during catch-up; wallets syncing very old chains; cross-chain reads pulling ancient certificates.","solutions":["Retry against another validator that still stores (or has already synced) those heights","Wait for the lagging validator to catch up if it is a peer-sync issue","Download the specific certificates by hash from a full-history source (e.g. an indexer or archiver) instead of by height","Ask the operator to disable pruning or restore from a snapshot for the affected range"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":"fn missing_certificates_by_heights(err: &NodeError) -> Option<&Vec<BlockHeight>> {\n    match err {\n        NodeError::MissingCertificatesByHeights { heights, .. } => Some(heights),\n        _ => None,\n    }\n}","tryCatchPattern":"match remote_node.download_certificates_by_heights(chain_id, heights.clone()).await {\n    Err(e) if missing_certificates_by_heights(&e).is_some() => {\n        // The listed heights are unavailable here; retry a validator with full history.\n        try_full_history_source(chain_id, heights).await\n    }\n    other => other,\n}","preventionTips":["Track which validators retain full history (no pruning) and route old-height downloads to them","Sync chains you depend on before validators prune the relevant range","On validator restarts from snapshot, wait until catch-up completes before serving download traffic"],"tags":["linera","validators","certificates","pruning","sync"],"backgroundTag":"block-not-found","analyzedSha":"6c226ddcb332ef55118dc8d0aafbd093d5420899","analyzedAt":"2026-08-22T22:49:09.787Z","schemaVersion":2},"datasetVersion":"2026-08-23T01:17:44.959Z"}