Skip to main content

load_binary_state

Function load_binary_state 

Source
pub fn load_binary_state(blockchain_db: &BlockchainDb, path: &Path) -> bool
Expand description

Load binary EVM state and populate the BlockchainDb.

Returns true if the binary state was loaded successfully, false otherwise. When successful, accounts (without code) and storage are populated in the MemDb. Bytecodes should be seeded separately from bytecodes.bin.

Returns false (rather than erroring) when path cannot be read or its contents fail the magic/version check or fail to decode as the expected bincode layout. A missing file (the normal cold-start case) is logged at debug; an actual read error (e.g. permission denied) and any magic/version/decode failure are logged at warn.