BitcoinKernel BlockValidationResult Enumeration BlockValidationResult A granular reason why a block failed validation. Paired with ValidationMode.invalid inside BlockValidationState to explain a rejection from processBlockHeader(_:state:) or processBlock(_:). enum BlockValidationResult Overview Maps to btck_BlockValidationResult constants in the kernel C API. Case descriptions follow Bitcoin Core’s BlockValidationResult enum in validation_state.h. Topics Enumeration Cases case cachedInvalidThe kernel has seen this block before and cached it as invalid without retaining the specific reason. Retry is pointless. case consensusRejected by Bitcoin’s consensus rules — script execution, coin-value balance, or other ConnectBlock-level checks failed. case headerLowWorkThe header chain the block would extend has cumulatively insufficient proof-of-work (below the minimum chain work checkpoint). The kernel won’t spend resources validating blocks on such chains. case invalidHeaderInvalid at the header level — proof-of-work below target, timestamp not greater than MTP, or malformed header structure. case invalidPrevAn ancestor of this block has already been rejected as invalid, so this block is rejected transitively without running full validation. case missingPrevThe block’s previous-block hash doesn’t match any block the kernel knows about. Provide the parent via processBlock(_:) first. case mutatedBlock contents don’t match the commitments in the header (merkle root mismatch, witness commitment mismatch). Typically a corruption or malicious-peer signal rather than a legitimate validity failure. case timeFutureBlock timestamp is more than 2 hours ahead of the node’s network-adjusted time — the kernel refuses to accept clearly future-dated blocks. case unsetThe state carries no rejection — either validation succeeded or the state has not yet been populated. Initializers init?(rawValue: UInt32) Instance Properties var description: String