ouroboros-consensus-shelley-0.1.0.1: Shelley ledger integration in the Ouroboros consensus layer
Safe Haskell None
Language Haskell2010

Ouroboros.Consensus.Shelley.Ledger

Synopsis

Documentation

newtype ApplyTxError era Source #

Constructors

ApplyTxError [ PredicateFailure ( EraRule "LEDGER" era)]

Instances

Instances details
Eq ( PredicateFailure ( EraRule "LEDGER" era)) => Eq ( ApplyTxError era)
Instance details

Defined in Cardano.Ledger.Shelley.API.Mempool

Show ( PredicateFailure ( EraRule "LEDGER" era)) => Show ( ApplyTxError era)
Instance details

Defined in Cardano.Ledger.Shelley.API.Mempool

( Era era, ToCBOR ( PredicateFailure ( EraRule "LEDGER" era))) => ToCBOR ( ApplyTxError era)
Instance details

Defined in Cardano.Ledger.Shelley.API.Mempool

( Era era, FromCBOR ( PredicateFailure ( EraRule "LEDGER" era))) => FromCBOR ( ApplyTxError era)
Instance details

Defined in Cardano.Ledger.Shelley.API.Mempool

Typeable era => ShowProxy ( ApplyTxError era :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => SerialiseNodeToClient ( ShelleyBlock proto era) ( ApplyTxError era) Source #
ApplyTxErr '(ShelleyBlock era)'
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

data family BlockQuery blk :: Type -> Type Source #

Different queries supported by the ledger, indexed by the result type.

Instances

Instances details
SameDepIndex ( BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

ShelleyCompatible proto era => ShowQuery ( BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

Methods

showResult :: BlockQuery ( ShelleyBlock proto era) result -> result -> String Source #

Eq ( BlockQuery ( ShelleyBlock proto era) result) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

SameDepIndex ( BlockQuery blk) => Eq ( SomeSecond BlockQuery blk)
Instance details

Defined in Ouroboros.Consensus.Ledger.Query

Show ( BlockQuery ( ShelleyBlock proto era) result) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

( forall result. Show ( BlockQuery blk result)) => Show ( SomeSecond BlockQuery blk)
Instance details

Defined in Ouroboros.Consensus.Ledger.Query

ShelleyCompatible proto era => SerialiseResult ( ShelleyBlock proto era) ( BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( Typeable era, Typeable proto) => ShowProxy ( BlockQuery ( ShelleyBlock proto era) :: Type -> Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( SomeSecond BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

data BlockQuery ( HardForkBlock xs) a
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Ledger.Query

data BlockQuery ( HardForkBlock xs) a where
data BlockQuery ( ShelleyBlock proto era) a Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

data BlockQuery ( ShelleyBlock proto era) a where

data family GenTx blk Source #

Generalized transaction

The mempool (and, accordingly, blocks) consist of "generalized transactions"; this could be "proper" transactions (transferring funds) but also other kinds of things such as update proposals, delegations, etc.

Instances

Instances details
( Typeable era, Typeable proto) => ShowProxy ( GenTx ( ShelleyBlock proto era) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Typeable era, Typeable proto) => ShowProxy ( TxId ( GenTx ( ShelleyBlock proto era)) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Typeable era, Typeable proto) => ShowProxy ( Validated ( GenTx ( ShelleyBlock proto era)) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( ShelleyBasedEra era, TranslateEra era WrapTx ) => TranslateEra era ( GenTx :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

ShelleyBasedEra era => Eq ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Eq ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Eq ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Ord ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Show ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Show ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Show ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Generic ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Associated Types

type Rep ( GenTx ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Associated Types

type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) :: Type -> Type Source #

ShelleyCompatible proto era => ToCBOR ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Crypto ( EraCrypto era), Typeable era, Typeable proto) => ToCBOR ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible proto era => FromCBOR ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Crypto ( EraCrypto era), Typeable era, Typeable proto) => FromCBOR ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => NoThunks ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

NoThunks ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => NoThunks ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => HasTxId ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Condense ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Condense ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( GenTx ( ShelleyBlock proto era)) Source #

The To/FromCBOR instances defined in cardano-ledger-specs use CBOR-in-CBOR to get the annotation.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( GenTx ( ShelleyBlock proto era)) Source #

Uses CBOR-in-CBOR in the To/FromCBOR instances to get the annotation.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

type TranslationError era ( GenTx :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type Rep ( GenTx ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

type Rep ( GenTx ( HardForkBlock xs)) = D1 (' MetaData "GenTx" "Ouroboros.Consensus.HardFork.Combinator.Mempool" "ouroboros-consensus-0.1.0.1-DT4Cvwf63DZKctsEvaJqCU" ' True ) ( C1 (' MetaCons "HardForkGenTx" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "getHardForkGenTx") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( OneEraGenTx xs))))
type Rep ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( GenTx ( ShelleyBlock proto era)) = D1 (' MetaData "GenTx" "Ouroboros.Consensus.Shelley.Ledger.Mempool" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyTx" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( TxId ( EraCrypto era))) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( Tx era))))
type Rep ( TxId ( GenTx ( HardForkBlock xs)))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

type Rep ( TxId ( GenTx ( HardForkBlock xs))) = D1 (' MetaData "TxId" "Ouroboros.Consensus.HardFork.Combinator.Mempool" "ouroboros-consensus-0.1.0.1-DT4Cvwf63DZKctsEvaJqCU" ' True ) ( C1 (' MetaCons "HardForkGenTxId" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "getHardForkGenTxId") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( OneEraGenTxId xs))))
type Rep ( Validated ( GenTx ( HardForkBlock xs)))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

type Rep ( Validated ( GenTx ( HardForkBlock xs))) = D1 (' MetaData "Validated" "Ouroboros.Consensus.HardFork.Combinator.Mempool" "ouroboros-consensus-0.1.0.1-DT4Cvwf63DZKctsEvaJqCU" ' True ) ( C1 (' MetaCons "HardForkValidatedGenTx" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "getHardForkValidatedGenTx") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( OneEraValidatedGenTx xs))))
type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) = D1 (' MetaData "Validated" "Ouroboros.Consensus.Shelley.Ledger.Mempool" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyValidatedTx" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( TxId ( EraCrypto era))) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( Validated ( Tx era)))))
newtype GenTx ( HardForkBlock xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

newtype TxId ( GenTx ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

newtype TxId ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

newtype Validated ( GenTx ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

data Validated ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

data GenTx ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

data family TxId tx Source #

A generalized transaction, GenTx , identifier.

Instances

Instances details
( Typeable era, Typeable proto) => ShowProxy ( TxId ( GenTx ( ShelleyBlock proto era)) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Eq ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Ord ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Show ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Crypto ( EraCrypto era), Typeable era, Typeable proto) => ToCBOR ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Crypto ( EraCrypto era), Typeable era, Typeable proto) => FromCBOR ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

NoThunks ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Condense ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

type Rep ( TxId ( GenTx ( HardForkBlock xs)))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

type Rep ( TxId ( GenTx ( HardForkBlock xs))) = D1 (' MetaData "TxId" "Ouroboros.Consensus.HardFork.Combinator.Mempool" "ouroboros-consensus-0.1.0.1-DT4Cvwf63DZKctsEvaJqCU" ' True ) ( C1 (' MetaCons "HardForkGenTxId" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "getHardForkGenTxId") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( OneEraGenTxId xs))))
newtype TxId ( GenTx ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

newtype TxId ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

data family Validated x Source #

" Validated " transaction or block

The ledger defines how to validate transactions and blocks. It's possible the type before and after validation may be distinct (eg Alonzo transactions), which originally motivated this family.

We also gain the related benefit that certain interface functions, such as those that reapply blocks, can have a more precise type now. TODO

Similarly, the Node-to-Client mini protocols can explicitly indicate that the client trusts the blocks from the local server, by having the server send Validated blocks to the client. TODO

Note that validation has different implications for a transaction than for a block. In particular, a validated transaction can be " reapplied " to different ledger states, whereas a validated block must only be " reapplied " to the exact same ledger state (eg as part of rebuilding from an on-disk ledger snapshot).

Since the ledger defines validation, see the ledger details for concrete examples of what determines the validity (wrt to a LedgerState ) of a transaction and/or block. Example properties include: a transaction's claimed inputs exist and are still unspent, a block carries a sufficient cryptographic signature, etc.

Instances

Instances details
( Typeable era, Typeable proto) => ShowProxy ( Validated ( GenTx ( ShelleyBlock proto era)) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Eq ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Show ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Generic ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Associated Types

type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) :: Type -> Type Source #

ShelleyBasedEra era => NoThunks ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( Validated ( GenTx ( HardForkBlock xs)))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

type Rep ( Validated ( GenTx ( HardForkBlock xs))) = D1 (' MetaData "Validated" "Ouroboros.Consensus.HardFork.Combinator.Mempool" "ouroboros-consensus-0.1.0.1-DT4Cvwf63DZKctsEvaJqCU" ' True ) ( C1 (' MetaCons "HardForkValidatedGenTx" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "getHardForkValidatedGenTx") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( OneEraValidatedGenTx xs))))
type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) = D1 (' MetaData "Validated" "Ouroboros.Consensus.Shelley.Ledger.Mempool" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyValidatedTx" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( TxId ( EraCrypto era))) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( Validated ( Tx era)))))
newtype Validated ( GenTx ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Mempool

data Validated ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

data family LedgerState blk Source #

Ledger state associated with a block

Instances

Instances details
( ShelleyBasedEra era, TranslateEra era ( ShelleyTip proto), TranslateEra era NewEpochState , TranslationError era NewEpochState ~ Void ) => TranslateEra era ( LedgerState :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

CanHardFork xs => Eq ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

ShelleyBasedEra era => Eq ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

CanHardFork xs => Show ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

ShelleyBasedEra era => Show ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Generic ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Associated Types

type Rep ( LedgerState ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

CanHardFork xs => NoThunks ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

ShelleyBasedEra era => NoThunks ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => NoThunks ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

GetTip ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

GetTip ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => IsLedger ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyCompatible proto era => ApplyBlock ( LedgerState ( ShelleyBlock proto era)) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyCompatible proto era => EncodeDisk ( ShelleyBlock proto era) ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDisk ( ShelleyBlock proto era) ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

type TranslationError era ( LedgerState :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type Rep ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( LedgerState ( ShelleyBlock proto era)) = D1 (' MetaData "LedgerState" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyLedgerState" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyLedgerTip") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( WithOrigin ( ShelleyTip proto era))) :*: ( S1 (' MetaSel (' Just "shelleyLedgerState") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( NewEpochState era)) :*: S1 (' MetaSel (' Just "shelleyLedgerTransition") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ShelleyTransition ))))
type Rep ( Ticked ( LedgerState ( HardForkBlock xs)))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Ledger

type Rep ( Ticked ( LedgerState ( HardForkBlock xs))) = D1 (' MetaData "Ticked" "Ouroboros.Consensus.HardFork.Combinator.Ledger" "ouroboros-consensus-0.1.0.1-DT4Cvwf63DZKctsEvaJqCU" ' False ) ( C1 (' MetaCons "TickedHardForkLedgerState" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "tickedHardForkLedgerStateTransition") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 TransitionInfo ) :*: S1 (' MetaSel (' Just "tickedHardForkLedgerStatePerEra") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( HardForkState ( Ticked :.: LedgerState ) xs))))
type Rep ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( Ticked ( LedgerState ( ShelleyBlock proto era))) = D1 (' MetaData "Ticked" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "TickedShelleyLedgerState" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "untickedShelleyLedgerTip") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( WithOrigin ( ShelleyTip proto era))) :*: ( S1 (' MetaSel (' Just "tickedShelleyLedgerTransition") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ShelleyTransition ) :*: S1 (' MetaSel (' Just "tickedShelleyLedgerState") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( NewEpochState era)))))
type LedgerCfg ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

type LedgerCfg ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type AuxLedgerEvent ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Ledger

type AuxLedgerEvent ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type LedgerErr ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Ledger

type LedgerErr ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

newtype LedgerState ( HardForkBlock xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

data Ticked ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Ledger

data Ticked ( LedgerState ( ShelleyBlock proto era)) Source #

Ticking only affects the state itself

Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type HeaderHash ( LedgerState blk)
Instance details

Defined in Ouroboros.Consensus.Ledger.Basics

data LedgerState ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

data family BlockConfig blk Source #

Static configuration required to work with this type of blocks

Instances

Instances details
ShelleyBasedEra era => Show ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Generic ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Associated Types

type Rep ( BlockConfig ( ShelleyBlock proto era)) :: Type -> Type Source #

CanHardFork xs => NoThunks ( BlockConfig ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

ShelleyBasedEra era => NoThunks ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

newtype BlockConfig ( HardForkBlock xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

data BlockConfig ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

data family CodecConfig blk Source #

Static configuration required for serialisation and deserialisation of types pertaining to this type of block.

Data family instead of type family to get better type inference.

Instances

Instances details
Generic ( CodecConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Associated Types

type Rep ( CodecConfig ( ShelleyBlock proto era)) :: Type -> Type Source #

CanHardFork xs => NoThunks ( CodecConfig ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

NoThunks ( CodecConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( CodecConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( CodecConfig ( ShelleyBlock proto era)) = D1 (' MetaData "CodecConfig" "Ouroboros.Consensus.Shelley.Ledger.Config" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyCodecConfig" ' PrefixI ' False ) ( U1 :: Type -> Type ))
newtype CodecConfig ( HardForkBlock xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

data CodecConfig ( ShelleyBlock proto era) Source #

No particular codec configuration is needed for Shelley

Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

data family StorageConfig blk Source #

Config needed for the NodeInitStorage class. Defined here to avoid circular dependencies.

Instances

Instances details
Generic ( StorageConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Associated Types

type Rep ( StorageConfig ( ShelleyBlock proto era)) :: Type -> Type Source #

CanHardFork xs => NoThunks ( StorageConfig ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

NoThunks ( StorageConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( StorageConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( StorageConfig ( ShelleyBlock proto era)) = D1 (' MetaData "StorageConfig" "Ouroboros.Consensus.Shelley.Ledger.Config" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyStorageConfig" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyStorageConfigSlotsPerKESPeriod") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 Word64 ) :*: S1 (' MetaSel (' Just "shelleyStorageConfigSecurityParam") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 SecurityParam )))
newtype StorageConfig ( HardForkBlock xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Basics

data StorageConfig ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

data family Header blk Source #

Instances

Instances details
( Typeable era, Typeable proto) => ShowProxy ( Header ( ShelleyBlock proto era) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyBasedEra era => ReconstructNestedCtxt Header ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => Eq ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => Show ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Generic ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Associated Types

type Rep ( Header ( ShelleyBlock proto era)) :: Type -> Type Source #

ShelleyCompatible proto era => ToCBOR ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => FromCBOR ( Annotator ( Header ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => NoThunks ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => Condense ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

SignedHeader ( ShelleyProtocolHeader proto) => SignedHeader ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Protocol

HasHeader blk => StandardHash ( Header blk)
Instance details

Defined in Ouroboros.Consensus.Block.Abstract

ShelleyCompatible proto era => HasHeader ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyBasedEra era => EncodeDiskDepIx ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => EncodeDiskDep ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyBasedEra era => DecodeDiskDepIx ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDiskDep ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( Header ( ShelleyBlock proto era)) Source #

CBOR-in-CBOR to be compatible with the wrapped ( Serialised ) variant.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => EncodeDisk ( ShelleyBlock proto era) ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDisk ( ShelleyBlock proto era) ( ByteString -> Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

type Rep ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

type Rep ( Header ( ShelleyBlock proto era)) = D1 (' MetaData "Header" "Ouroboros.Consensus.Shelley.Ledger.Block" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyHeader" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyHeaderRaw") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( ShelleyProtocolHeader proto)) :*: S1 (' MetaSel (' Just "shelleyHeaderHash") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( ShelleyHash ( ProtoCrypto proto)))))
type BlockProtocol ( Header blk)
Instance details

Defined in Ouroboros.Consensus.Block.Abstract

newtype Header ( HardForkBlock xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Block

type Signed ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Protocol

type HeaderHash ( Header blk)
Instance details

Defined in Ouroboros.Consensus.Block.Abstract

data Header ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

class HasHeader ( Header blk) => GetHeader blk where Source #

Methods

getHeader :: blk -> Header blk Source #

blockMatchesHeader :: Header blk -> blk -> Bool Source #

Check whether the header is the header of the block.

For example, by checking whether the hash of the body stored in the header matches that of the block.

headerIsEBB :: Header blk -> Maybe EpochNo Source #

When the given header is the header of an Epoch Boundary Block, returns its epoch number.

data family NestedCtxt_ blk :: ( Type -> Type ) -> Type -> Type Source #

Context identifying what kind of block we have

In almost all places we will use NestedCtxt rather than NestedCtxt_ .

Instances

Instances details
SameDepIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

TrivialDependency ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Associated Types

type TrivialIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #

Show ( NestedCtxt_ ( ShelleyBlock proto era) f a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

data NestedCtxt_ ( HardForkBlock xs) a b
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Block

data NestedCtxt_ ( HardForkBlock xs) a b where
data NestedCtxt_ ( ShelleyBlock proto era) f a Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

data NestedCtxt_ ( ShelleyBlock proto era) f a where
type TrivialIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

type TrivialIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) = f ( ShelleyBlock proto era)

data family Ticked st Source #

" Ticked " piece of state ( LedgerState , LedgerView , ChainIndepState )

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 (or forecast).

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

( SListI xs, Show ( Ticked a)) => Show ( Ticked ( HardForkLedgerView_ ( K a :: Type -> Type ) xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Protocol.LedgerView

Show ( Ticked a) => Show ( Ticked ( K a x))
Instance details

Defined in Ouroboros.Consensus.Ticked

Generic ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => NoThunks ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

IsLedger l => GetTip ( Ticked ( LedgerDB l))
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.InMemory

IsLedger ( LedgerState blk) => GetTip ( Ticked ( ExtLedgerState blk))
Instance details

Defined in Ouroboros.Consensus.Ledger.Extended

GetTip ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Show ( Ticked (f a)) => Show (( Ticked :.: f) a)
Instance details

Defined in Ouroboros.Consensus.Ticked

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 Rep ( Ticked ( LedgerState ( HardForkBlock xs)))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Ledger

type Rep ( Ticked ( LedgerState ( HardForkBlock xs))) = D1 (' MetaData "Ticked" "Ouroboros.Consensus.HardFork.Combinator.Ledger" "ouroboros-consensus-0.1.0.1-DT4Cvwf63DZKctsEvaJqCU" ' False ) ( C1 (' MetaCons "TickedHardForkLedgerState" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "tickedHardForkLedgerStateTransition") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 TransitionInfo ) :*: S1 (' MetaSel (' Just "tickedHardForkLedgerStatePerEra") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( HardForkState ( Ticked :.: LedgerState ) xs))))
type Rep ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( Ticked ( LedgerState ( ShelleyBlock proto era))) = D1 (' MetaData "Ticked" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "TickedShelleyLedgerState" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "untickedShelleyLedgerTip") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( WithOrigin ( ShelleyTip proto era))) :*: ( S1 (' MetaSel (' Just "tickedShelleyLedgerTransition") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ShelleyTransition ) :*: S1 (' MetaSel (' Just "tickedShelleyLedgerState") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( NewEpochState era)))))
newtype Ticked ( LedgerView c)

Ledger view at a particular slot

Instance details

Defined in Ouroboros.Consensus.Protocol.TPraos

data Ticked ( HardForkChainDepState xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Protocol

data Ticked ( LedgerDB l)

Ticking the ledger DB just ticks the current state

We don't push the new state into the DB until we apply a block.

Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.InMemory

data Ticked ( ExtLedgerState blk)
Instance details

Defined in Ouroboros.Consensus.Ledger.Extended

newtype Ticked ( WrapChainDepState blk)
Instance details

Defined in Ouroboros.Consensus.TypeFamilyWrappers

newtype Ticked ( WrapLedgerView blk)
Instance details

Defined in Ouroboros.Consensus.TypeFamilyWrappers

data Ticked ( HeaderState blk)
Instance details

Defined in Ouroboros.Consensus.HeaderValidation

data Ticked ( LedgerState ( HardForkBlock xs))
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Ledger

data Ticked ( LedgerState ( ShelleyBlock proto era)) Source #

Ticking only affects the state itself

Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

data Ticked ( PraosState c)

Ticked PraosState

Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

data Ticked ( TPraosState c)

Ticked TPraosState

Instance details

Defined in Ouroboros.Consensus.Protocol.TPraos

newtype Ticked ( LedgerView c)

Ledger view at a particular slot

Instance details

Defined in Ouroboros.Consensus.Protocol.Praos

type HeaderHash ( Ticked l)
Instance details

Defined in Ouroboros.Consensus.Ledger.Basics

data Ticked ( HardForkLedgerView_ f xs)
Instance details

Defined in Ouroboros.Consensus.HardFork.Combinator.Protocol.LedgerView

newtype Ticked ( K a x)
Instance details

Defined in Ouroboros.Consensus.Ticked

class ( ShelleyBasedEra era, GetLedgerView era, State ( EraRule "PPUP" era) ~ PPUPState era, Default ( State ( EraRule "PPUP" era)), HasField "_maxBBSize" ( PParams era) Natural , HasField "_maxBHSize" ( PParams era) Natural , HasField "_maxTxSize" ( PParams era) Natural , HasField "_a0" ( PParams era) NonNegativeInterval , HasField "_nOpt" ( PParams era) Natural , HasField "_rho" ( PParams era) UnitInterval , HasField "_tau" ( PParams era) UnitInterval , ValidateScript era, FromCBOR ( PParams era), ToCBOR ( PParams era), HasField "_protocolVersion" ( PParamsDelta era) ( StrictMaybe ProtVer ), FromCBOR ( PParamsDelta era), AdditionalGenesisConfig era ~ TranslationContext era, ToCBORGroup ( TxSeq era), NoThunks ( TranslationContext era), FromCBOR ( Annotator ( Witnesses era)), ToCBOR ( Witnesses era), Eq ( TxSeq era), Show ( TxSeq era), FromCBOR ( Annotator ( TxSeq era))) => ShelleyBasedEra era Source #

The ledger already defines ShelleyBasedEra as the top-level constraint on an era, however, consensus often needs some more functionality than the ledger currently provides.

Either the functionality shouldn't or can't live in the ledger, in which case it can be part and remain part of ShelleyBasedEra . Or, the functionality should live in the ledger, but hasn't yet been added to the ledger, or it hasn't yet been propagated to this repository, in which case it can be added to this class until that is the case.

By having the same name as the class defined in ledger, we can, if this class becomes redundant, switch to the ledger-defined one without having to update all the code using it. We can just export the right one from this module.

TODO Currently we include some constraints on the update state which are needed to determine the hard fork point. In the future this should be replaced with an appropriate API - see https://github.com/input-output-hk/ouroboros-network/issues/2890

Minimal complete definition

shelleyBasedEraName , applyShelleyBasedTx

Instances

Instances details
( PraosCrypto c, DSignable c ( Hash c EraIndependentTxBody )) => ShelleyBasedEra ( AlonzoEra c) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Eras

PraosCrypto c => ShelleyBasedEra ( BabbageEra c) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Eras

( PraosCrypto c, DSignable c ( Hash c EraIndependentTxBody )) => ShelleyBasedEra ( ShelleyEra c) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Eras

( PraosCrypto c, DSignable c ( Hash c EraIndependentTxBody )) => ShelleyBasedEra ( AllegraEra c) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Eras

( PraosCrypto c, DSignable c ( Hash c EraIndependentTxBody )) => ShelleyBasedEra ( MaryEra c) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Eras

verifyHeaderIntegrity Source #

Arguments

:: ProtocolHeaderSupportsKES proto
=> Word64

Slots per KES period

-> ShelleyProtocolHeader proto
-> Bool

Verify that the signature on a header is correct and valid.

newtype ShelleyHash crypto Source #

Instances

Instances details
Eq ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

Ord ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

Show ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

Generic ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

Associated Types

type Rep ( ShelleyHash crypto) :: Type -> Type Source #

Crypto crypto => ToCBOR ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

Crypto crypto => FromCBOR ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

NoThunks ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

Crypto crypto => Serialise ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

Condense ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

type Rep ( ShelleyHash crypto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Protocol.Abstract

type Rep ( ShelleyHash crypto) = D1 (' MetaData "ShelleyHash" "Ouroboros.Consensus.Shelley.Protocol.Abstract" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' True ) ( C1 (' MetaCons "ShelleyHash" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "unShelleyHash") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( Hash crypto EraIndependentBlockHeader ))))

data ShelleyBlock proto era Source #

Shelley-based block type.

This block is parametrised over both the (ledger) era and the protocol.

Instances

Instances details
( Typeable era, Typeable proto) => ShowProxy ( GenTx ( ShelleyBlock proto era) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Typeable era, Typeable proto) => ShowProxy ( TxId ( GenTx ( ShelleyBlock proto era)) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Typeable era, Typeable proto) => ShowProxy ( Validated ( GenTx ( ShelleyBlock proto era)) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Typeable era, Typeable proto) => ShowProxy ( Header ( ShelleyBlock proto era) :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyBasedEra era => ReconstructNestedCtxt Header ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

HasNestedContent f ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

( ShelleyBasedEra era, TranslateEra era WrapTx ) => TranslateEra era ( WrapValidatedGenTx :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

( ShelleyBasedEra era, TranslateEra era WrapTx ) => TranslateEra era ( GenTx :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

( ShelleyBasedEra era, TranslateEra era ( ShelleyTip proto), TranslateEra era NewEpochState , TranslationError era NewEpochState ~ Void ) => TranslateEra era ( LedgerState :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

ShelleyBasedEra era => Eq ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Eq ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Eq ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Eq ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyCompatible proto era => Eq ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Ord ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Show ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Show ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Show ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => Show ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => Show ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

ShelleyCompatible proto era => Show ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Generic ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Associated Types

type Rep ( GenTx ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Associated Types

type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) :: Type -> Type Source #

Generic ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Associated Types

type Rep ( LedgerState ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Associated Types

type Rep ( BlockConfig ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( CodecConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Associated Types

type Rep ( CodecConfig ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( StorageConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Associated Types

type Rep ( StorageConfig ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Associated Types

type Rep ( Header ( ShelleyBlock proto era)) :: Type -> Type Source #

Generic ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyCompatible proto era => ToCBOR ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Crypto ( EraCrypto era), Typeable era, Typeable proto) => ToCBOR ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible proto era => ToCBOR ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => FromCBOR ( Annotator ( Header ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => FromCBOR ( Annotator ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => FromCBOR ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

( Crypto ( EraCrypto era), Typeable era, Typeable proto) => FromCBOR ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => NoThunks ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

NoThunks ( TxId ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => NoThunks ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => NoThunks ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => NoThunks ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

NoThunks ( CodecConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

NoThunks ( StorageConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

ShelleyCompatible proto era => NoThunks ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyBasedEra era => NoThunks ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => HasTxId ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

GetTip ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

GetTip ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => IsLedger ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => Condense ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Condense ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible proto era => Condense ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

SameDepIndex ( BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

SignedHeader ( ShelleyProtocolHeader proto) => SignedHeader ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Protocol

ShelleyCompatible proto era => HasHeader ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => ShowQuery ( BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

Methods

showResult :: BlockQuery ( ShelleyBlock proto era) result -> result -> String Source #

ShelleyBasedEra era => EncodeDiskDepIx ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => EncodeDiskDep ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyBasedEra era => DecodeDiskDepIx ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDiskDep ( NestedCtxt Header ) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => ApplyBlock ( LedgerState ( ShelleyBlock proto era)) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

( Typeable era, Typeable proto) => ShowProxy ( ShelleyBlock proto era :: Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Eq ( BlockQuery ( ShelleyBlock proto era) result) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

ShelleyCompatible proto era => Eq ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Show ( BlockQuery ( ShelleyBlock proto era) result) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

ShelleyCompatible proto era => Show ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => ToCBOR ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

( ShelleyCompatible proto era, LedgerSupportsProtocol ( ShelleyBlock proto era)) => SerialiseConstraintsHFC ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

ShelleyCompatible proto era => SerialiseNodeToNodeConstraints ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClientConstraints ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( ShelleyCompatible proto era, LedgerSupportsProtocol ( ShelleyBlock proto era)) => RunNode ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node

ShelleyCompatible proto era => SerialiseDiskConstraints ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( ShelleyCompatible proto era, LedgerSupportsProtocol ( ShelleyBlock proto era)) => NoHardForks ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

( ShelleyCompatible proto era, LedgerSupportsProtocol ( ShelleyBlock proto era)) => SingleEraBlock ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

ShelleyCompatible proto era => NodeInitStorage ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Common

ShelleyCompatible proto era => QueryLedger ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

ConfigSupportsNode ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Common

ShelleyCompatible proto era => HasPartialLedgerConfig ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

Associated Types

type PartialLedgerConfig ( ShelleyBlock proto era) Source #

HasHardForkHistory ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Associated Types

type HardForkIndices ( ShelleyBlock proto era) :: [ Type ] Source #

( ShelleyCompatible ( Praos crypto) era, ShelleyCompatible ( TPraos crypto) era, crypto ~ EraCrypto era, TranslateProto ( TPraos crypto) ( Praos crypto)) => LedgerSupportsProtocol ( ShelleyBlock ( Praos crypto) era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.SupportsProtocol

( ShelleyCompatible ( TPraos crypto) era, crypto ~ EraCrypto era) => LedgerSupportsProtocol ( ShelleyBlock ( TPraos crypto) era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.SupportsProtocol

ShelleyCompatible proto era => HasBinaryBlockInfo ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyBasedEra era => InspectLedger ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Inspect

ShelleyCompatible proto era => HasAnnTip ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Associated Types

type TipInfo ( ShelleyBlock proto era) Source #

ShelleyCompatible proto era => BasicEnvelopeValidation ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyCompatible proto era => ValidateEnvelope ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyCompatible p ( BabbageEra c) => TxLimits ( ShelleyBlock p ( BabbageEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible p ( AlonzoEra c) => TxLimits ( ShelleyBlock p ( AlonzoEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible p ( MaryEra c) => TxLimits ( ShelleyBlock p ( MaryEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible p ( AllegraEra c) => TxLimits ( ShelleyBlock p ( AllegraEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible p ( ShelleyEra c) => TxLimits ( ShelleyBlock p ( ShelleyEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible proto era => LedgerSupportsMempool ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyBasedEra era => HasTxs ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

ShelleyCompatible proto era => BlockSupportsMetrics ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node

ShelleyCompatible proto era => BlockSupportsProtocol ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Protocol

ShelleyCompatible proto era => CommonProtocolParams ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

c ~ EraCrypto era => LedgerSupportsPeerSelection ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.PeerSelection

ShelleyCompatible proto era => UpdateLedger ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyCompatible proto era => GetPrevHash ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => GetHeader ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => ConvertRawHash ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => Condense ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

SameDepIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

TrivialDependency ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

Associated Types

type TrivialIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #

HasNetworkProtocolVersion ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

SupportedNetworkProtocolVersion ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

( ShelleyCompatible proto era, LedgerSupportsProtocol ( ShelleyBlock proto era)) => SupportedNetworkProtocolVersion ( ShelleyBlockHFC proto era) Source #

Forward to the ShelleyBlock instance. Only supports HardForkNodeToNodeDisabled , which is compatible with nodes running with ShelleyBlock .

Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

ShelleyCompatible proto era => StandardHash ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => HasHeader ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) SlotNo Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( GenTx ( ShelleyBlock proto era)) Source #

The To/FromCBOR instances defined in cardano-ledger-specs use CBOR-in-CBOR to get the annotation.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

SerialiseNodeToNode ( ShelleyBlock proto era) ( SerialisedHeader ( ShelleyBlock proto era)) Source #

We use CBOR-in-CBOR

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( Header ( ShelleyBlock proto era)) Source #

CBOR-in-CBOR to be compatible with the wrapped ( Serialised ) variant.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

SerialiseNodeToNode ( ShelleyBlock proto era) ( Serialised ( ShelleyBlock proto era)) Source #

Serialised uses CBOR-in-CBOR by default.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyBasedEra era => SerialiseNodeToClient ( ShelleyBlock proto era) ( ApplyTxError era) Source #
ApplyTxErr '(ShelleyBlock era)'
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( GenTxId ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( GenTx ( ShelleyBlock proto era)) Source #

Uses CBOR-in-CBOR in the To/FromCBOR instances to get the annotation.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

SerialiseNodeToClient ( ShelleyBlock proto era) ( Serialised ( ShelleyBlock proto era)) Source #

Serialised uses CBOR-in-CBOR by default.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseResult ( ShelleyBlock proto era) ( BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => EncodeDisk ( ShelleyBlock proto era) ( AnnTip ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( ShelleyCompatible proto era, EraCrypto era ~ c, PraosCrypto c) => EncodeDisk ( ShelleyBlock proto era) ( PraosState c) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( ShelleyCompatible proto era, EraCrypto era ~ c, PraosCrypto c) => EncodeDisk ( ShelleyBlock proto era) ( TPraosState c) Source #
ChainDepState (BlockProtocol (ShelleyBlock era))
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => EncodeDisk ( ShelleyBlock proto era) ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => EncodeDisk ( ShelleyBlock proto era) ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDisk ( ShelleyBlock proto era) ( AnnTip ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( ShelleyCompatible proto era, EraCrypto era ~ c, PraosCrypto c) => DecodeDisk ( ShelleyBlock proto era) ( PraosState c) Source #
ChainDepState (BlockProtocol (ShelleyBlock era))
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( ShelleyCompatible proto era, EraCrypto era ~ c, PraosCrypto c) => DecodeDisk ( ShelleyBlock proto era) ( TPraosState c) Source #
ChainDepState (BlockProtocol (ShelleyBlock era))
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDisk ( ShelleyBlock proto era) ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

( Typeable era, Typeable proto) => ShowProxy ( BlockQuery ( ShelleyBlock proto era) :: Type -> Type ) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

ShelleyCompatible proto era => SerialiseNodeToNode ( ShelleyBlock proto era) ( ShelleyBlock proto era) Source #

CBOR-in-CBOR for the annotation. This also makes it compatible with the wrapped ( Serialised ) variant.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( SomeSecond BlockQuery ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => SerialiseNodeToClient ( ShelleyBlock proto era) ( ShelleyBlock proto era) Source #

CBOR-in-CBOR for the annotation. This also makes it compatible with the wrapped ( Serialised ) variant.

Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => EncodeDisk ( ShelleyBlock proto era) ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDisk ( ShelleyBlock proto era) ( ByteString -> Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

ShelleyCompatible proto era => DecodeDisk ( ShelleyBlock proto era) ( ByteString -> ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Serialisation

Show ( NestedCtxt_ ( ShelleyBlock proto era) f a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

( ShelleyCompatible proto era, LedgerSupportsProtocol ( ShelleyBlock proto era)) => SerialiseHFC '[ ShelleyBlock proto era] Source #

Use the default implementations. This means the serialisation of blocks includes an era wrapper. Each block should do this from the start to be prepared for future hard forks without having to do any bit twiddling.

Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type TranslationError era ( WrapValidatedGenTx :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type TranslationError era ( GenTx :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type TranslationError era ( LedgerState :.: ShelleyBlock proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type Rep ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( GenTx ( ShelleyBlock proto era)) = D1 (' MetaData "GenTx" "Ouroboros.Consensus.Shelley.Ledger.Mempool" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyTx" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( TxId ( EraCrypto era))) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( Tx era))))
type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( Validated ( GenTx ( ShelleyBlock proto era))) = D1 (' MetaData "Validated" "Ouroboros.Consensus.Shelley.Ledger.Mempool" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyValidatedTx" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( TxId ( EraCrypto era))) :*: S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( Validated ( Tx era)))))
type Rep ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( LedgerState ( ShelleyBlock proto era)) = D1 (' MetaData "LedgerState" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyLedgerState" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyLedgerTip") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( WithOrigin ( ShelleyTip proto era))) :*: ( S1 (' MetaSel (' Just "shelleyLedgerState") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( NewEpochState era)) :*: S1 (' MetaSel (' Just "shelleyLedgerTransition") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ShelleyTransition ))))
type Rep ( BlockConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( CodecConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( CodecConfig ( ShelleyBlock proto era)) = D1 (' MetaData "CodecConfig" "Ouroboros.Consensus.Shelley.Ledger.Config" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyCodecConfig" ' PrefixI ' False ) ( U1 :: Type -> Type ))
type Rep ( StorageConfig ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( StorageConfig ( ShelleyBlock proto era)) = D1 (' MetaData "StorageConfig" "Ouroboros.Consensus.Shelley.Ledger.Config" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyStorageConfig" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyStorageConfigSlotsPerKESPeriod") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 Word64 ) :*: S1 (' MetaSel (' Just "shelleyStorageConfigSecurityParam") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 SecurityParam )))
type Rep ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

type Rep ( Header ( ShelleyBlock proto era)) = D1 (' MetaData "Header" "Ouroboros.Consensus.Shelley.Ledger.Block" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyHeader" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyHeaderRaw") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( ShelleyProtocolHeader proto)) :*: S1 (' MetaSel (' Just "shelleyHeaderHash") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( ShelleyHash ( ProtoCrypto proto)))))
type Rep ( Ticked ( LedgerState ( ShelleyBlock proto era))) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( Ticked ( LedgerState ( ShelleyBlock proto era))) = D1 (' MetaData "Ticked" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "TickedShelleyLedgerState" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "untickedShelleyLedgerTip") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( WithOrigin ( ShelleyTip proto era))) :*: ( S1 (' MetaSel (' Just "tickedShelleyLedgerTransition") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ShelleyTransition ) :*: S1 (' MetaSel (' Just "tickedShelleyLedgerState") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( NewEpochState era)))))
newtype TxId ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

data Validated ( GenTx ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type LedgerCfg ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type AuxLedgerEvent ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type LedgerErr ( LedgerState ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

data Ticked ( LedgerState ( ShelleyBlock proto era)) Source #

Ticking only affects the state itself

Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Signed ( Header ( ShelleyBlock proto era)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Protocol

data BlockQuery ( ShelleyBlock proto era) a Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Query

data BlockQuery ( ShelleyBlock proto era) a where
type PartialLedgerConfig ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type HardForkIndices ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type HardForkIndices ( ShelleyBlock proto era) = '[ ShelleyBlock proto era]
type LedgerUpdate ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Inspect

type LedgerWarning ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Inspect

type TipInfo ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

type OtherHeaderEnvelopeError ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type CannotForge ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Common

type ForgeStateInfo ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Common

type ForgeStateUpdateError ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Node.Common

type TxMeasure ( ShelleyBlock p ( MaryEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type TxMeasure ( ShelleyBlock p ( AllegraEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type TxMeasure ( ShelleyBlock p ( ShelleyEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type TxMeasure ( ShelleyBlock p ( BabbageEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type TxMeasure ( ShelleyBlock p ( AlonzoEra c)) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

data GenTx ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type ApplyTxErr ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

data LedgerState ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type BlockProtocol ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Protocol

type BlockProtocol ( ShelleyBlock proto era) = proto
data BlockConfig ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

data CodecConfig ( ShelleyBlock proto era) Source #

No particular codec configuration is needed for Shelley

Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

data StorageConfig ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

data Header ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

data NestedCtxt_ ( ShelleyBlock proto era) f a Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

data NestedCtxt_ ( ShelleyBlock proto era) f a where
type TrivialIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

type TrivialIndex ( NestedCtxt_ ( ShelleyBlock proto era) f) = f ( ShelleyBlock proto era)
type BlockNodeToClientVersion ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

type BlockNodeToNodeVersion ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

type HeaderHash ( ShelleyBlock proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Block

class ( ShelleyBasedEra era, ShelleyProtocol proto, Eq ( ShelleyProtocolHeader proto), Show ( ShelleyProtocolHeader proto), NoThunks ( ShelleyProtocolHeader proto), ToCBOR ( ShelleyProtocolHeader proto), FromCBOR ( Annotator ( ShelleyProtocolHeader proto)), Show ( CannotForgeError proto), SelectView proto ~ PraosChainSelectView ( EraCrypto era), SignedHeader ( ShelleyProtocolHeader proto), DecodeDisk ( ShelleyBlock proto era) ( ChainDepState proto), EncodeDisk ( ShelleyBlock proto era) ( ChainDepState proto), EraCrypto era ~ ProtoCrypto proto, HasPartialConsensusConfig proto) => ShelleyCompatible proto era Source #

fromShelleyPrevHash :: EraCrypto era ~ ProtoCrypto proto => PrevHash ( EraCrypto era) -> ChainHash ( ShelleyBlock proto era) Source #

From cardano-ledger-specs to ouroboros-consensus

toShelleyPrevHash :: EraCrypto era ~ ProtoCrypto proto => ChainHash ( Header ( ShelleyBlock proto era)) -> PrevHash ( EraCrypto era) Source #

From ouroboros-consensus to cardano-ledger-specs

data ShelleyNodeToClientVersion Source #

Constructors

ShelleyNodeToClientVersion1
ShelleyNodeToClientVersion2

New queries introduced

ShelleyNodeToClientVersion3

New query introduced

ShelleyNodeToClientVersion4

New queries introduced

ShelleyNodeToClientVersion5

New queries introduced: GetRewardInfoPools

Instances

Instances details
Bounded ShelleyNodeToClientVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Enum ShelleyNodeToClientVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Eq ShelleyNodeToClientVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Ord ShelleyNodeToClientVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Show ShelleyNodeToClientVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

data ShelleyNodeToNodeVersion Source #

Instances

Instances details
Bounded ShelleyNodeToNodeVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Enum ShelleyNodeToNodeVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Eq ShelleyNodeToNodeVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Ord ShelleyNodeToNodeVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

Show ShelleyNodeToNodeVersion Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.NetworkProtocolVersion

verifyBlockIntegrity :: ShelleyCompatible proto era => Word64 -> ShelleyBlock proto era -> Bool Source #

Verifies whether the block is not corrupted by checking its signature and witnesses.

data CompactGenesis era Source #

Compact variant of ShelleyGenesis with some fields erased that are only used on start-up and that should not be kept in memory forever.

Concretely:

  • The sgInitialFunds field is erased. It is only used to set up the initial UTxO in tests and testnets.
  • The sgStaking field is erased. It is only used to register initial stake pools in tests and benchmarks.

Instances

Instances details
Eq ( CompactGenesis era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Show ( CompactGenesis era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Generic ( CompactGenesis era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Associated Types

type Rep ( CompactGenesis era) :: Type -> Type Source #

Era era => ToCBOR ( CompactGenesis era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

Era era => FromCBOR ( CompactGenesis era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

ShelleyBasedEra era => NoThunks ( CompactGenesis era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( CompactGenesis era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Config

type Rep ( CompactGenesis era) = D1 (' MetaData "CompactGenesis" "Ouroboros.Consensus.Shelley.Ledger.Config" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' True ) ( C1 (' MetaCons "CompactGenesis" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "getCompactGenesis") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( ShelleyGenesis era))))

data ShelleyLedgerEvent era Source #

All events emitted by the Shelley ledger API

Constructors

ShelleyLedgerEventBBODY ( Event ( EraRule "BBODY" era))

An event emitted when (re)applying a block

ShelleyLedgerEventTICK ( Event ( EraRule "TICK" era))

An event emitted during the chain tick

newtype ShelleyTransition Source #

Information required to determine the hard fork point from Shelley to the next ledger

Constructors

ShelleyTransitionInfo

Fields

  • shelleyAfterVoting :: Word32

    The number of blocks in this epoch past the voting deadline

    We record this to make sure that we can tell the HFC about hard forks if and only if we are certain:

    1. Blocks that came in within an epoch after the 4k/f voting deadline are not relevant (10k f - 2 * 3k f).
    2. Since there are slots between blocks, we are probably only sure that there will be no more relevant block when we have seen the first block after the deadline.
    3. If we count how many blocks we have seen post deadline, and we have reached k of them, we know that that last pre-deadline block won't be rolled back anymore.
    4. At this point we can look at the ledger state and see which proposals we accepted in the voting period, if any, and notify the HFC is one of them indicates a transition.

Instances

Instances details
Eq ShelleyTransition Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Show ShelleyTransition Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Generic ShelleyTransition Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

NoThunks ShelleyTransition Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ShelleyTransition Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ShelleyTransition = D1 (' MetaData "ShelleyTransition" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' True ) ( C1 (' MetaCons "ShelleyTransitionInfo" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyAfterVoting") ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 Word32 )))

data ShelleyTip proto era Source #

Instances

Instances details
( ShelleyBasedEra era, ShelleyBasedEra ( PreviousEra era), EraCrypto ( PreviousEra era) ~ EraCrypto era) => TranslateEra era ( ShelleyTip proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

Associated Types

type TranslationError era ( ShelleyTip proto) Source #

Eq ( ShelleyTip proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Show ( ShelleyTip proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Generic ( ShelleyTip proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Associated Types

type Rep ( ShelleyTip proto era) :: Type -> Type Source #

NoThunks ( ShelleyTip proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type TranslationError era ( ShelleyTip proto) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.ShelleyHFC

type Rep ( ShelleyTip proto era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( ShelleyTip proto era) = D1 (' MetaData "ShelleyTip" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyTip" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyTipSlotNo") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 SlotNo ) :*: ( S1 (' MetaSel (' Just "shelleyTipBlockNo") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 BlockNo ) :*: S1 (' MetaSel (' Just "shelleyTipHash") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( HeaderHash ( ShelleyBlock proto era))))))

data ShelleyLedgerConfig era Source #

Instances

Instances details
Generic ( ShelleyLedgerConfig era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => NoThunks ( ShelleyLedgerConfig era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( ShelleyLedgerConfig era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( ShelleyLedgerConfig era) = D1 (' MetaData "ShelleyLedgerConfig" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "ShelleyLedgerConfig" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "shelleyLedgerCompactGenesis") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( CompactGenesis era)) :*: ( S1 (' MetaSel (' Just "shelleyLedgerGlobals") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 Globals ) :*: S1 (' MetaSel (' Just "shelleyLedgerTranslationContext") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( TranslationContext era)))))

newtype ShelleyLedgerError era Source #

Instances

Instances details
ShelleyBasedEra era => Eq ( ShelleyLedgerError era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => Show ( ShelleyLedgerError era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

Generic ( ShelleyLedgerError era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

ShelleyBasedEra era => NoThunks ( ShelleyLedgerError era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( ShelleyLedgerError era) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Ledger

type Rep ( ShelleyLedgerError era) = D1 (' MetaData "ShelleyLedgerError" "Ouroboros.Consensus.Shelley.Ledger.Ledger" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' True ) ( C1 (' MetaCons "BBodyError" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 ( BlockTransitionError era))))

shelleyEraParamsNeverHardForks :: ShelleyGenesis era -> EraParams Source #

Separate variant of shelleyEraParams to be used for a Shelley-only chain.

data WithTop a Source #

Add a unique top element to a lattice.

TODO This should be relocated to `cardano-base:Data.Measure'.

Constructors

NotTop a
Top

Instances

Instances details
Eq a => Eq ( WithTop a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Ord a => Ord ( WithTop a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Show a => Show ( WithTop a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Generic ( WithTop a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Associated Types

type Rep ( WithTop a) :: Type -> Type Source #

Measure a => BoundedMeasure ( WithTop a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Measure a => Measure ( WithTop a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( WithTop a) Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep ( WithTop a) = D1 (' MetaData "WithTop" "Ouroboros.Consensus.Shelley.Ledger.Mempool" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "NotTop" ' PrefixI ' False ) ( S1 (' MetaSel (' Nothing :: Maybe Symbol ) ' NoSourceUnpackedness ' NoSourceStrictness ' DecidedLazy ) ( Rec0 a)) :+: C1 (' MetaCons "Top" ' PrefixI ' False ) ( U1 :: Type -> Type ))

data AlonzoMeasure Source #

Instances

Instances details
Eq AlonzoMeasure Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Show AlonzoMeasure Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Generic AlonzoMeasure Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

BoundedMeasure AlonzoMeasure Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

Measure AlonzoMeasure Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep AlonzoMeasure Source #
Instance details

Defined in Ouroboros.Consensus.Shelley.Ledger.Mempool

type Rep AlonzoMeasure = D1 (' MetaData "AlonzoMeasure" "Ouroboros.Consensus.Shelley.Ledger.Mempool" "ouroboros-consensus-shelley-0.1.0.1-Kwox0dapAHUG8fY5XKE0pO" ' False ) ( C1 (' MetaCons "AlonzoMeasure" ' PrefixI ' True ) ( S1 (' MetaSel (' Just "byteSize") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ByteSize ) :*: S1 (' MetaSel (' Just "exUnits") ' NoSourceUnpackedness ' SourceStrict ' DecidedStrict ) ( Rec0 ( ExUnits' ( WithTop Natural )))))

fixedBlockBodyOverhead :: Num a => a Source #

txInBlockSize is used to estimate how many transactions we can grab from the Mempool to put into the block we are going to forge without exceeding the maximum block body size according to the ledger. If we exceed that limit, we will have forged a block that is invalid according to the ledger. We ourselves won't even adopt it, causing us to lose our slot, something we must try to avoid.

For this reason it is better to overestimate the size of a transaction than to underestimate. The only downside is that we maybe could have put one (or more?) transactions extra in that block.

As the sum of the serialised transaction sizes is not equal to the size of the serialised block body ( TxSeq ) consisting of those transactions (see cardano-node#1545 for an example), we account for some extra overhead per transaction as a safety margin.

Also see perTxOverhead .

forgeShelleyBlock Source #

Arguments

:: forall m era proto. ( ShelleyCompatible proto era, TxLimits ( ShelleyBlock proto era), Monad m)
=> HotKey ( EraCrypto era) m
-> CanBeLeader proto
-> TopLevelConfig ( ShelleyBlock proto era)
-> Overrides ( ShelleyBlock proto era)

How to override max tx capacity defined by ledger

-> BlockNo

Current block number

-> SlotNo

Current slot number

-> TickedLedgerState ( ShelleyBlock proto era)

Current ledger

-> [ Validated ( GenTx ( ShelleyBlock proto era))]

Txs to add in the block

-> IsLeader proto
-> m ( ShelleyBlock proto era)