pub(crate) fn justify_qc_matches_parent<T: NodeType>(
proposal: &Proposal<T>,
epoch_height: u64,
) -> Result<EpochNumber, MalformedProposal>Expand description
The justify QC must certify the block before this proposal, in the epoch that block’s height falls in.
A certificate’s epoch selects the committee whose stake table and threshold its signatures are weighed against. Unlike the proposal’s own epoch, it is covered by those signatures, so a mismatch is not something a proposer can produce by relabelling a genuine certificate.
A justify QC at the genesis view must certify the genesis block. Such a certificate is not signed, so its epoch and block number are otherwise whatever the proposer wrote, and together they would let it claim any epoch for the proposal.
Returns that epoch, which the QC checks resolve their membership through.