From 041a2693b75287adf106d9dd73b03aedf2fe8f19 Mon Sep 17 00:00:00 2001 From: Alfredo Garcia Date: Mon, 27 Dec 2021 23:56:31 -0300 Subject: [PATCH] change format of funding stream consensus rule (#3285) Co-authored-by: teor --- zebra-consensus/src/block/check.rs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/zebra-consensus/src/block/check.rs b/zebra-consensus/src/block/check.rs index 66826942b..46dc593b2 100644 --- a/zebra-consensus/src/block/check.rs +++ b/zebra-consensus/src/block/check.rs @@ -135,10 +135,14 @@ pub fn subsidy_is_valid(block: &Block, network: Network) -> Result<(), BlockErro let funding_streams = subsidy::funding_streams::funding_stream_values(height, network) .expect("We always expect a funding stream hashmap response even if empty"); - // Consensus rule:[Canopy onward] The coinbase transaction at block height `height` - // MUST contain at least one output per funding stream `fs` active at `height`, - // that pays `fs.Value(height)` zatoshi in the prescribed way to the stream's - // recipient address represented by `fs.AddressList[fs.AddressIndex(height)] + // # Consensus + // + // > [Canopy onward] The coinbase transaction at block height `height` + // > MUST contain at least one output per funding stream `fs` active at `height`, + // > that pays `fs.Value(height)` zatoshi in the prescribed way to the stream's + // > recipient address represented by `fs.AddressList[fs.AddressIndex(height)] + // + // https://zips.z.cash/protocol/protocol.pdf#fundingstreams for (receiver, expected_amount) in funding_streams { let address = subsidy::funding_streams::funding_stream_address(height, network, receiver);