Module constants
Expand description
Blockdata constants.
This module provides various constants relating to the blockchain and consensus code. In particular, it defines the genesis block and its single transaction.
Structs§
- Chain
Hash - The uniquely identifying hash of the target blockchain.
Constants§
- COINBASE_
MATURITY - Number of blocks needed for an output from a coinbase transaction to be spendable.
- DIFFCHANGE_
INTERVAL - How many blocks between diffchanges.
- DIFFCHANGE_
TIMESPAN - How much time on average should occur between diffchanges.
- MAX_
BLOCK_ SIGOPS_ COST - The maximum allowed number of signature check operations in a block.
- MAX_
SCRIPTNUM_ VALUE - Maximum allowed value for an integer in Script.
- MAX_
SCRIPT_ ELEMENT_ SIZE - The maximum allowed script size.
- PUBKEY_
ADDRESS_ PREFIX_ MAIN - Mainnet (bitcoin) pubkey address prefix.
- PUBKEY_
ADDRESS_ PREFIX_ TEST - Test (tesnet, signet, regtest) pubkey address prefix.
- SCRIPT_
ADDRESS_ PREFIX_ MAIN - Mainnet (bitcoin) script address prefix.
- SCRIPT_
ADDRESS_ PREFIX_ TEST - Test (tesnet, signet, regtest) script address prefix.
- SUBSIDY_
HALVING_ INTERVAL - How may blocks between halvings.
- TARGET_
BLOCK_ SPACING - How many seconds between blocks we expect on average.
- WITNESS_
SCALE_ FACTOR - The factor that non-witness serialization data is multiplied by during weight calculation.
Functions§
- genesis_
block - Constructs and returns the genesis block.