ouroboros-consensus-protocol-0.9.0.2: Cardano consensus protocols
Safe HaskellSafe-Inferred
LanguageHaskell2010

Ouroboros.Consensus.Protocol.Praos

Synopsis

Documentation

data family ConsensusConfig p Source #

Static configuration required to run the consensus protocol

Every method in the ConsensusProtocol class takes the consensus configuration as a parameter, so having this as a data family rather than a type family resolves most ambiguity.

Defined out of the class so that protocols can define this type without having to define the entire protocol at the same time (or indeed in the same module).

Instances

Instances details
Generic (ConsensusConfig (Praos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (ConsensusConfig (Praos c)) ∷ TypeType #

Generic (ConsensusConfig (TPraos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.TPraos

Associated Types

type Rep (ConsensusConfig (TPraos c)) ∷ TypeType #

PraosCrypto c ⇒ NoThunks (ConsensusConfig (Praos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

PraosCrypto c ⇒ NoThunks (ConsensusConfig (TPraos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.TPraos

type Rep (ConsensusConfig (Praos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (ConsensusConfig (Praos c)) = D1 ('MetaData "ConsensusConfig" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "PraosConfig" 'PrefixI 'True) (S1 ('MetaSel ('Just "praosParams") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 PraosParams) :*: S1 ('MetaSel ('Just "praosEpochInfo") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (EpochInfo (Except PastHorizonException)))))
type Rep (ConsensusConfig (TPraos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.TPraos

type Rep (ConsensusConfig (TPraos c)) = D1 ('MetaData "ConsensusConfig" "Ouroboros.Consensus.Protocol.TPraos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "TPraosConfig" 'PrefixI 'True) (S1 ('MetaSel ('Just "tpraosParams") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 TPraosParams) :*: S1 ('MetaSel ('Just "tpraosEpochInfo") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (EpochInfo (Except PastHorizonException)))))
data ConsensusConfig (Praos c) Source #

Static configuration

Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

data ConsensusConfig (TPraos c) Source #

Static configuration

Instance details

Defined in Ouroboros.Consensus.Protocol.TPraos

data Praos c Source #

Instances

Instances details
Generic (ConsensusConfig (Praos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (ConsensusConfig (Praos c)) ∷ TypeType #

PraosCrypto c ⇒ NoThunks (ConsensusConfig (Praos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

PraosCrypto c ⇒ ConsensusProtocol (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

PraosCrypto c ⇒ PraosProtocolSupportsNode (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

c1 ~ c2 ⇒ TranslateProto (TPraos c1) (Praos c2) Source #

We can translate between TPraos and Praos, provided:

  • They share the same HASH algorithm
  • They share the same ADDRHASH algorithm
  • They share the same DSIGN verification keys
  • They share the same VRF verification keys
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (ConsensusConfig (Praos c)) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (ConsensusConfig (Praos c)) = D1 ('MetaData "ConsensusConfig" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "PraosConfig" 'PrefixI 'True) (S1 ('MetaSel ('Just "praosParams") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 PraosParams) :*: S1 ('MetaSel ('Just "praosEpochInfo") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (EpochInfo (Except PastHorizonException)))))
type CanBeLeader (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type ChainDepState (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

data ConsensusConfig (Praos c) Source #

Static configuration

Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type IsLeader (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type LedgerView (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type SelectView (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type ValidateView (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type ValidationErr (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type PraosProtocolSupportsNodeCrypto (Praos c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

data PraosCannotForge c Source #

Expresses that, whilst we believe ourselves to be a leader for this slot, we are nonetheless unable to forge a block.

Constructors

PraosCannotForgeKeyNotUsableYet

The KES key in our operational certificate can't be used because the current (wall clock) period is before the start period of the key. current KES period.

Note: the opposite case, i.e., the wall clock period being after the end period of the key, is caught when trying to update the key in updateForgeState.

Fields

  • !KESPeriod

    Current KES period according to the wallclock slot, i.e., the KES period in which we want to use the key.

  • !KESPeriod

    Start KES period of the KES key.

Instances

Instances details
Generic (PraosCannotForge c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (PraosCannotForge c) ∷ TypeType #

PraosCrypto c ⇒ Show (PraosCannotForge c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosCannotForge c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosCannotForge c) = D1 ('MetaData "PraosCannotForge" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "PraosCannotForgeKeyNotUsableYet" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 KESPeriod) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 KESPeriod)))

data PraosFields c toSign Source #

Constructors

PraosFields 

Fields

Instances

Instances details
Generic (PraosFields c toSign) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (PraosFields c toSign) ∷ TypeType #

Methods

fromPraosFields c toSign → Rep (PraosFields c toSign) x #

toRep (PraosFields c toSign) x → PraosFields c toSign #

(Show toSign, PraosCrypto c) ⇒ Show (PraosFields c toSign) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Methods

showsPrecIntPraosFields c toSign → ShowS #

showPraosFields c toSign → String #

showList ∷ [PraosFields c toSign] → ShowS #

(NoThunks toSign, PraosCrypto c) ⇒ NoThunks (PraosFields c toSign) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosFields c toSign) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosFields c toSign) = D1 ('MetaData "PraosFields" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "PraosFields" 'PrefixI 'True) (S1 ('MetaSel ('Just "praosSignature") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (SignedKES c toSign)) :*: S1 ('MetaSel ('Just "praosToSign") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 toSign)))

newtype PraosIsLeader c Source #

Assembled proof that the issuer has the right to issue a block in the selected slot.

Instances

Instances details
Generic (PraosIsLeader c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (PraosIsLeader c) ∷ TypeType #

Methods

fromPraosIsLeader c → Rep (PraosIsLeader c) x #

toRep (PraosIsLeader c) x → PraosIsLeader c #

PraosCrypto c ⇒ NoThunks (PraosIsLeader c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosIsLeader c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosIsLeader c) = D1 ('MetaData "PraosIsLeader" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'True) (C1 ('MetaCons "PraosIsLeader" 'PrefixI 'True) (S1 ('MetaSel ('Just "praosIsLeaderVrfRes") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (CertifiedVRF c InputVRF))))

data PraosParams Source #

Praos parameters that are node independent

Constructors

PraosParams 

Fields

Instances

Instances details
Generic PraosParams Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep PraosParamsTypeType #

NoThunks PraosParams Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep PraosParams Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep PraosParams = D1 ('MetaData "PraosParams" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "PraosParams" 'PrefixI 'True) ((S1 ('MetaSel ('Just "praosSlotsPerKESPeriod") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64) :*: (S1 ('MetaSel ('Just "praosLeaderF") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 ActiveSlotCoeff) :*: S1 ('MetaSel ('Just "praosSecurityParam") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SecurityParam))) :*: (S1 ('MetaSel ('Just "praosMaxKESEvo") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64) :*: (S1 ('MetaSel ('Just "praosMaxMajorPV") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 MaxMajorProtVer) :*: S1 ('MetaSel ('Just "praosRandomnessStabilisationWindow") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64)))))

data PraosState c Source #

Praos consensus state.

We track the last slot and the counters for operational certificates, as well as a series of nonces which get updated in different ways over the course of an epoch.

Constructors

PraosState 

Fields

Instances

Instances details
Generic (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (PraosState c) ∷ TypeType #

Methods

fromPraosState c → Rep (PraosState c) x #

toRep (PraosState c) x → PraosState c #

Show (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Methods

showsPrecIntPraosState c → ShowS #

showPraosState c → String #

showList ∷ [PraosState c] → ShowS #

PraosCrypto c ⇒ FromCBOR (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

PraosCrypto c ⇒ ToCBOR (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Methods

toCBORPraosState c → Encoding Source #

encodedSizeExpr ∷ (∀ t. ToCBOR t ⇒ Proxy t → Size) → Proxy (PraosState c) → Size Source #

encodedListSizeExpr ∷ (∀ t. ToCBOR t ⇒ Proxy t → Size) → Proxy [PraosState c] → Size Source #

Eq (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Methods

(==)PraosState c → PraosState c → Bool #

(/=)PraosState c → PraosState c → Bool #

PraosCrypto c ⇒ NoThunks (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

PraosCrypto c ⇒ Serialise (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosState c) = D1 ('MetaData "PraosState" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "PraosState" 'PrefixI 'True) ((S1 ('MetaSel ('Just "praosStateLastSlot") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (WithOrigin SlotNo)) :*: (S1 ('MetaSel ('Just "praosStateOCertCounters") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Map (KeyHash 'BlockIssuer c) Word64)) :*: S1 ('MetaSel ('Just "praosStateEvolvingNonce") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Nonce))) :*: ((S1 ('MetaSel ('Just "praosStateCandidateNonce") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Nonce) :*: S1 ('MetaSel ('Just "praosStateEpochNonce") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Nonce)) :*: (S1 ('MetaSel ('Just "praosStateLabNonce") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Nonce) :*: S1 ('MetaSel ('Just "praosStateLastEpochBlockNonce") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Nonce)))))
data Ticked (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

data PraosToSign c Source #

Fields arising from praos execution which must be included in the block signature.

Constructors

PraosToSign 

Fields

Instances

Instances details
Generic (PraosToSign c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (PraosToSign c) ∷ TypeType #

Methods

fromPraosToSign c → Rep (PraosToSign c) x #

toRep (PraosToSign c) x → PraosToSign c #

PraosCrypto c ⇒ Show (PraosToSign c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Methods

showsPrecIntPraosToSign c → ShowS #

showPraosToSign c → String #

showList ∷ [PraosToSign c] → ShowS #

PraosCrypto c ⇒ NoThunks (PraosToSign c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosToSign c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosToSign c) = D1 ('MetaData "PraosToSign" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (C1 ('MetaCons "PraosToSign" 'PrefixI 'True) ((S1 ('MetaSel ('Just "praosToSignIssuerVK") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (VKey 'BlockIssuer c)) :*: S1 ('MetaSel ('Just "praosToSignVrfVK") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (VerKeyVRF c))) :*: (S1 ('MetaSel ('Just "praosToSignVrfRes") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (CertifiedVRF c InputVRF)) :*: S1 ('MetaSel ('Just "praosToSignOCert") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (OCert c)))))

data PraosValidationErr c Source #

Errors which we might encounter

Instances

Instances details
Generic (PraosValidationErr c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

Associated Types

type Rep (PraosValidationErr c) ∷ TypeType #

PraosCrypto c ⇒ Show (PraosValidationErr c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

PraosCrypto c ⇒ Eq (PraosValidationErr c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

PraosCrypto c ⇒ NoThunks (PraosValidationErr c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosValidationErr c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type Rep (PraosValidationErr c) = D1 ('MetaData "PraosValidationErr" "Ouroboros.Consensus.Protocol.Praos" "ouroboros-consensus-protocol-0.9.0.2-inplace" 'False) (((C1 ('MetaCons "VRFKeyUnknown" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (KeyHash 'StakePool c))) :+: C1 ('MetaCons "VRFKeyWrongVRFKey" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (KeyHash 'StakePool c)) :*: (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Hash c (VerKeyVRF c))) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (Hash c (VerKeyVRF c)))))) :+: (C1 ('MetaCons "VRFKeyBadProof" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SlotNo) :*: (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Nonce) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (CertifiedVRF (VRF c) InputVRF)))) :+: (C1 ('MetaCons "VRFLeaderValueTooBig" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Natural) :*: (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Rational) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ActiveSlotCoeff))) :+: C1 ('MetaCons "KESBeforeStartOCERT" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 KESPeriod) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 KESPeriod))))) :+: ((C1 ('MetaCons "KESAfterEndOCERT" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 KESPeriod) :*: (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 KESPeriod) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64))) :+: (C1 ('MetaCons "CounterTooSmallOCERT" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64)) :+: C1 ('MetaCons "CounterOverIncrementedOCERT" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64)))) :+: (C1 ('MetaCons "InvalidSignatureOCERT" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64) :*: (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 KESPeriod) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 String))) :+: (C1 ('MetaCons "InvalidKesSignatureOCERT" 'PrefixI 'False) ((S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word)) :*: (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word) :*: (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Word64) :*: S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 String)))) :+: C1 ('MetaCons "NoCounterForKeyHashOCERT" 'PrefixI 'False) (S1 ('MetaSel ('NothingMaybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (KeyHash 'BlockIssuer c)))))))

data family Ticked st Source #

" Ticked " piece of state, either LedgerState or ChainDepState

Ticking refers to the passage of time (the ticking of the clock). When a piece of state is marked as ticked, it means that time-related changes have been applied to the state. There are exactly two methods in the interface that do that: tickChainDepState and applyChainTickLedgerResult.

Also note that a successful forecast forecastFor (ledgerViewForecastAt cfg st) slot must equal protocolLedgerView cfg (applyChainTick cfg slot st). Thus a LedgerView can only be projected from a Ticked state, but cannot itself be ticked.

Some examples of time related changes:

  • Scheduled delegations might have been applied in Byron
  • New leader schedule computed for Shelley
  • Transition from Byron to Shelley activated in the hard fork combinator.
  • Nonces switched out at the start of a new epoch.

Instances

Instances details
Show (Ticked ()) 
Instance details

Defined in Ouroboros.Consensus.Ticked

Methods

showsPrecIntTicked () → ShowS #

showTicked () → String #

showList ∷ [Ticked ()] → ShowS #

Show (Ticked (f a)) ⇒ Show ((Ticked :.: f) a) 
Instance details

Defined in Ouroboros.Consensus.Ticked

Methods

showsPrecInt → (Ticked :.: f) a → ShowS #

show ∷ (Ticked :.: f) a → String #

showList ∷ [(Ticked :.: f) a] → ShowS #

NoThunks (Ticked (f a)) ⇒ NoThunks ((Ticked :.: f) a) 
Instance details

Defined in Ouroboros.Consensus.Ticked

data Ticked () 
Instance details

Defined in Ouroboros.Consensus.Ticked

type HeaderHash (Ticked l ∷ Type) 
Instance details

Defined in Ouroboros.Consensus.Ticked

type HeaderHash (Ticked l ∷ Type) = HeaderHash l
data Ticked (PraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

data Ticked (TPraosState c) Source # 
Instance details

Defined in Ouroboros.Consensus.Protocol.TPraos

forgePraosFields ∷ (PraosCrypto c, KESignable c toSign, Monad m) ⇒ HotKey c m → CanBeLeader (Praos c) → IsLeader (Praos c) → (PraosToSign c → toSign) → m (PraosFields c toSign) Source #

For testing purposes