Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- mkSomeConsensusProtocolShelley ∷ NodeShelleyProtocolConfiguration → Maybe ProtocolFilepaths → ExceptT ShelleyProtocolInstantiationError IO SomeConsensusProtocol
- data GenesisReadError
- newtype GenesisValidationError = GenesisValidationErrors [ValidationErr]
- data PraosLeaderCredentialsError
- data ShelleyProtocolInstantiationError
- genesisHashToPraosNonce ∷ GenesisHash → Nonce
- readGenesis ∷ GenesisFile → Maybe GenesisHash → ExceptT GenesisReadError IO (ShelleyGenesis StandardCrypto, GenesisHash)
- readGenesisAny ∷ FromJSON genesis ⇒ GenesisFile → Maybe GenesisHash → ExceptT GenesisReadError IO (genesis, GenesisHash)
- readLeaderCredentials ∷ Maybe ProtocolFilepaths → ExceptT PraosLeaderCredentialsError IO [ShelleyLeaderCredentials StandardCrypto]
- validateGenesis ∷ ShelleyGenesis StandardCrypto → ExceptT GenesisValidationError IO ()
Documentation
mkSomeConsensusProtocolShelley ∷ NodeShelleyProtocolConfiguration → Maybe ProtocolFilepaths → ExceptT ShelleyProtocolInstantiationError IO SomeConsensusProtocol Source #
Make SomeConsensusProtocol
using the Shelley instance.
This lets us handle multiple protocols in a generic way.
This also serves a purpose as a sanity check that we have all the necessary type class instances available.
Errors
data GenesisReadError Source #
GenesisReadFileError !FilePath !IOException | |
GenesisHashMismatch !GenesisHash !GenesisHash | |
GenesisDecodeError !FilePath !String |
Instances
Show GenesisReadError Source # | |
Defined in Cardano.Node.Protocol.Shelley showsPrec ∷ Int → GenesisReadError → ShowS # show ∷ GenesisReadError → String # showList ∷ [GenesisReadError] → ShowS # | |
Error GenesisReadError Source # | |
Defined in Cardano.Node.Protocol.Shelley |
newtype GenesisValidationError Source #
Instances
data PraosLeaderCredentialsError Source #
data ShelleyProtocolInstantiationError Source #
GenesisReadError GenesisReadError | |
GenesisValidationError GenesisValidationError | |
PraosLeaderCredentialsError PraosLeaderCredentialsError |
Reusable parts
readGenesis ∷ GenesisFile → Maybe GenesisHash → ExceptT GenesisReadError IO (ShelleyGenesis StandardCrypto, GenesisHash) Source #
readGenesisAny ∷ FromJSON genesis ⇒ GenesisFile → Maybe GenesisHash → ExceptT GenesisReadError IO (genesis, GenesisHash) Source #