Skip to content

Commit

Permalink
Integrate api changes
Browse files Browse the repository at this point in the history
  • Loading branch information
crocodile-dentist committed Oct 10, 2024
1 parent af5016a commit 5c65f2a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions cardano-node/src/Cardano/Node/Protocol/Byron.hs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import Cardano.Node.Protocol.Types
import Cardano.Node.Tracing.Era.Byron ()
import Cardano.Node.Tracing.Era.HardFork ()
import Cardano.Node.Tracing.Tracers.ChainDB ()
import Cardano.Node.Types
import Cardano.Node.Types as Node
import Cardano.Prelude (canonicalDecodePretty)
import Cardano.Tracing.OrphanInstances.Byron ()
import Cardano.Tracing.OrphanInstances.HardFork ()
Expand Down Expand Up @@ -83,7 +83,7 @@ mkSomeConsensusProtocolByron NodeByronProtocolConfiguration {
}

readGenesis :: GenesisFile
-> Maybe GenesisHash
-> Maybe Node.GenesisHash
-> RequiresNetworkMagic
-> ExceptT ByronProtocolInstantiationError IO
Genesis.Config
Expand All @@ -110,9 +110,9 @@ readGenesis (GenesisFile file) mbExpectedGenesisHash ncReqNetworkMagic = do

_ -> return ()

fromByronGenesisHash :: Genesis.GenesisHash -> GenesisHash
fromByronGenesisHash :: Genesis.GenesisHash -> Node.GenesisHash
fromByronGenesisHash (Genesis.GenesisHash h) =
GenesisHash
Node.GenesisHash
. fromMaybe impossible
. Crypto.hashFromBytes
. Byron.Crypto.hashToBytes
Expand Down Expand Up @@ -154,7 +154,7 @@ readLeaderCredentials genesisConfig

data ByronProtocolInstantiationError =
CanonicalDecodeFailure !FilePath !Text
| GenesisHashMismatch !GenesisHash !GenesisHash -- actual, expected
| GenesisHashMismatch !Node.GenesisHash !Node.GenesisHash -- actual, expected
| DelegationCertificateFilepathNotSpecified
| GenesisConfigurationError !FilePath !Genesis.ConfigurationError
| GenesisReadError !FilePath !Genesis.GenesisDataError
Expand Down

0 comments on commit 5c65f2a

Please sign in to comment.