ouroboros-consensus-0.18.0.0: Consensus layer for the Ouroboros blockchain protocol
Safe HaskellSafe-Inferred
LanguageHaskell2010

Ouroboros.Consensus.HardFork.Combinator.Forging

Synopsis

Documentation

type HardForkCannotForge xs = OneEraCannotForge xs Source #

If we cannot forge, it's because the current era could not forge

data HardForkForgeStateInfo xs where Source #

For each era in which we want to forge blocks, we have a BlockForging, and thus ForgeStateInfo.

When we update the hard fork forge state, we only update the forge state of the current era. However, the current era might not have a forge state as it lacks a BlockForging.

TODO #2766: expire past ForgeState

Constructors

CurrentEraLacksBlockForgingEraIndex (x ': (y ': xs)) → HardForkForgeStateInfo (x ': (y ': xs))

There is no BlockForging record for the current era.

CurrentEraForgeStateUpdatedOneEraForgeStateInfo xs → HardForkForgeStateInfo xs

The ForgeState of the current era was updated.

type HardForkForgeStateUpdateError xs = OneEraForgeStateUpdateError xs Source #

For each era in which we want to forge blocks, we have a BlockForging, and thus ForgeStateUpdateError.

hardForkBlockForging Source #

Arguments

∷ ∀ m xs. (CanHardFork xs, Monad m) 
Text

Used as the forgeLabel, the labels of the given BlockForgings will be ignored.

NonEmptyOptNP (BlockForging m) xs 
BlockForging m (HardForkBlock xs)