Module zebra_chain::parameters::subsidy
source · Expand description
Constants and calculations for Block Subsidy and Funding Streams
This module contains the consensus parameters which are required for verification.
Some consensus parameters change based on network upgrades. Each network upgrade happens at a particular block height. Some parameters have a value (or function) before the upgrade height, at the upgrade height, and after the upgrade height. (For example, the value of the reserved field in the block header during the Heartwood upgrade.)
Typically, consensus parameters are accessed via a function that takes a
Network
and block::Height
.
Structs§
- A funding stream recipient as specified in protocol specification §7.10.1
- Funding stream recipients and height ranges.
- The post-NU6 funding streams for Mainnet as described in ZIP-1015.
- The post-NU6 funding streams for Testnet as described in ZIP-1015.
- The pre-NU6 funding streams for Mainnet as described in [protocol specification §7.10.1][7.10.1] [7.10.1]: https://zips.z.cash/protocol/protocol.pdf#zip214fundingstreams
- The pre-NU6 funding streams for Testnet as described in [protocol specification §7.10.1][7.10.1] [7.10.1]: https://zips.z.cash/protocol/protocol.pdf#zip214fundingstreams
Enums§
- The funding stream receiver categories.
Constants§
- Used as a multiplier to get the new halving interval after Blossom.
- Number of addresses for each funding stream in the Mainnet. In the spec (protocol specification §7.10) this is defined as:
fs.addressindex(fs.endheight - 1)
however we know this value beforehand so we prefer to make it a constant instead. - Number of addresses for each funding stream in the Testnet. In the spec (protocol specification §7.10) this is defined as:
fs.addressindex(fs.endheight - 1)
however we know this value beforehand so we prefer to make it a constant instead. - Address change interval function here as a constant as described in protocol specification §7.10.1.
- List of addresses for the ECC funding stream in the Mainnet.
- List of addresses for the ECC funding stream in the Testnet.
- List of addresses for the Major Grants funding stream in the Mainnet.
- List of addresses for the Major Grants funding stream in the Testnet.
- Denominator as described in protocol specification §7.10.1.
- The specification for pre-NU6 funding stream receivers, a URL that links to ZIP-214.
- List of addresses for the Zcash Foundation funding stream in the Mainnet.
- List of addresses for the Zcash Foundation funding stream in the Testnet.
- The specification for post-NU6 funding stream and lockbox receivers, a URL that links to ZIP-1015.
- The largest block subsidy, used before the first halving.
- After Blossom the block time is reduced to 75 seconds but halving period should remain around 4 years.
- Number of addresses for each post-NU6 funding stream on Mainnet. In the spec (protocol specification §7.10) this is defined as:
fs.addressindex(fs.endheight - 1)
however we know this value beforehand so we prefer to make it a constant instead. - Number of addresses for each post-NU6 funding stream in the Testnet. In the spec (protocol specification §7.10) this is defined as:
fs.addressindex(fs.endheight - 1)
however we know this value beforehand so we prefer to make it a constant instead. - List of addresses for the Major Grants post-NU6 funding stream on Mainnet administered by the Financial Privacy Fund (FPF).
- List of addresses for the Major Grants post-NU6 funding stream on Testnet administered by the Financial Privacy Fund (FPF).
- Halving is at about every 4 years, before Blossom block time is 150 seconds.
Traits§
- Functionality specific to block subsidy-related consensus rules
Functions§
- Returns the address change period as described in protocol specification §7.10
- The first block height of the halving at the provided halving index for a network.