diff --git a/cardano-api/internal/Cardano/Api/Query.hs b/cardano-api/internal/Cardano/Api/Query.hs index 3bfd4d30ac..3248681557 100644 --- a/cardano-api/internal/Cardano/Api/Query.hs +++ b/cardano-api/internal/Cardano/Api/Query.hs @@ -146,6 +146,8 @@ import Data.Text (Text) import qualified Data.Text as Text import Data.Word (Word64) import GHC.Stack +import qualified Ouroboros.Consensus.Shelley.Ledger.Query as Consensus +import qualified Ouroboros.Consensus.Shelley.Ledger.Query as Consensus -- ---------------------------------------------------------------------------- @@ -711,7 +713,7 @@ toConsensusQueryShelleyBased sbe = \case creds' = Set.map toShelleyStakeCredential creds QueryLedgerPeerSnapshot -> - Some (consensusQueryInEraInMode era (Consensus.GetCBOR Consensus.GetPeerSnapshot)) + Some (consensusQueryInEraInMode era (Consensus.GetCBOR Consensus.GetBigLedgerPeerSnapshot)) where era = shelleyBasedToCardanoEra sbe @@ -979,7 +981,7 @@ fromConsensusQueryResultShelleyBased _ QueryStakeVoteDelegatees{} q' delegs' = fromConsensusQueryResultShelleyBased _ QueryLedgerPeerSnapshot q' serLedgerPeerSnapshot = case q' of - Consensus.GetCBOR Consensus.GetPeerSnapshot -> serLedgerPeerSnapshot + Consensus.GetCBOR Consensus.GetBigLedgerPeerSnapshot -> serLedgerPeerSnapshot _ -> fromConsensusQueryResultMismatch -- | This should /only/ happen if we messed up the mapping in 'toConsensusQuery'