-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Ledger and Plutus dependencies for the Cardano Node 8.12 relea…
…se. (#1142) As a part of the [Cardano Node 8.12 release](IntersectMBO/cardano-node#5868) this PR contains - [x] updated Ledger dependencies. - [x] updated Plutus dependencies - [x] updated `ouroboros-network` dependencies, ... and the code changes needed to make them work.
- Loading branch information
Showing
33 changed files
with
217 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 5 additions & 0 deletions
5
...sensus-cardano/changelog.d/20240617_202003_alexander.esgen_cardano_node_8_12.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
### Breaking | ||
|
||
- Changed `GetStakeDistribution` and `GetPoolDistr` queries to return a | ||
Consensus-vendored version of `PoolDistr` (instead of using the one from | ||
Ledger, as it changed in a backwards-incompatible manner). |
Binary file modified
BIN
+4 Bytes
(110%)
...ensus-cardano/golden/cardano/QueryVersion2/CardanoNodeToClientVersion12/ApplyTxErr_Conway
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/ExtLedgerState_Allegra
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/ExtLedgerState_Alonzo
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/ExtLedgerState_Babbage
Binary file not shown.
Binary file modified
BIN
+4 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/ExtLedgerState_Conway
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/ExtLedgerState_Mary
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/ExtLedgerState_Shelley
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/LedgerState_Allegra
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/LedgerState_Alonzo
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/LedgerState_Babbage
Binary file not shown.
Binary file modified
BIN
+4 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/LedgerState_Conway
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/LedgerState_Mary
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/cardano/disk/LedgerState_Shelley
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/shelley/disk/ExtLedgerState
Binary file not shown.
Binary file modified
BIN
+3 Bytes
(100%)
ouroboros-consensus-cardano/golden/shelley/disk/LedgerState
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
71 changes: 71 additions & 0 deletions
71
ouroboros-consensus-cardano/src/shelley/Ouroboros/Consensus/Shelley/Ledger/Query/Types.hs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
{-# LANGUAGE DataKinds #-} | ||
{-# LANGUAGE DeriveAnyClass #-} | ||
{-# LANGUAGE DeriveGeneric #-} | ||
{-# LANGUAGE DerivingStrategies #-} | ||
{-# LANGUAGE GeneralizedNewtypeDeriving #-} | ||
{-# LANGUAGE OverloadedStrings #-} | ||
|
||
-- | This module contains copies of older versions of types from Ledger in order | ||
-- to retain backwards-compatibility. Eventually, types likes this should be | ||
-- defined in Ledger instead of here, see | ||
-- <https://github.com/IntersectMBO/cardano-ledger/issues/4415>. | ||
module Ouroboros.Consensus.Shelley.Ledger.Query.Types ( | ||
IndividualPoolStake (..) | ||
, PoolDistr (..) | ||
, fromLedgerIndividualPoolStake | ||
, fromLedgerPoolDistr | ||
) where | ||
|
||
import Cardano.Ledger.Binary (DecCBOR (..), EncCBOR (..), | ||
decodeRecordNamed, encodeListLen) | ||
import Cardano.Ledger.Crypto (Crypto) | ||
import Cardano.Ledger.Keys (Hash) | ||
import qualified Cardano.Ledger.PoolDistr as SL | ||
import qualified Cardano.Ledger.Shelley.API as SL | ||
import Data.Map.Strict (Map) | ||
import qualified Data.Map.Strict as Map | ||
import GHC.Generics (Generic) | ||
import NoThunks.Class | ||
|
||
-- | Copy of 'SL.IndividualPoolStake' before | ||
-- <https://github.com/IntersectMBO/cardano-ledger/pull/4324>. | ||
data IndividualPoolStake c = IndividualPoolStake { | ||
individualPoolStake :: !Rational | ||
, individualPoolStakeVrf :: !(Hash c (SL.VerKeyVRF c)) | ||
} | ||
deriving stock (Show, Eq, Generic) | ||
deriving anyclass (NoThunks) | ||
|
||
fromLedgerIndividualPoolStake :: SL.IndividualPoolStake c -> IndividualPoolStake c | ||
fromLedgerIndividualPoolStake ips = IndividualPoolStake { | ||
individualPoolStake = SL.individualPoolStake ips | ||
, individualPoolStakeVrf = SL.individualPoolStakeVrf ips | ||
} | ||
|
||
instance Crypto c => EncCBOR (IndividualPoolStake c) where | ||
encCBOR (IndividualPoolStake stake vrf) = | ||
mconcat | ||
[ encodeListLen 2 | ||
, encCBOR stake | ||
, encCBOR vrf | ||
] | ||
|
||
instance Crypto c => DecCBOR (IndividualPoolStake c) where | ||
decCBOR = | ||
decodeRecordNamed "IndividualPoolStake" (const 2) $ | ||
IndividualPoolStake | ||
<$> decCBOR | ||
<*> decCBOR | ||
|
||
-- | Copy of 'SL.PoolDistr' before | ||
-- <https://github.com/IntersectMBO/cardano-ledger/pull/4324>. | ||
newtype PoolDistr c = PoolDistr { | ||
unPoolDistr :: Map (SL.KeyHash SL.StakePool c) (IndividualPoolStake c) | ||
} | ||
deriving stock (Show, Eq, Generic) | ||
deriving newtype (EncCBOR, DecCBOR) | ||
|
||
fromLedgerPoolDistr :: SL.PoolDistr c -> PoolDistr c | ||
fromLedgerPoolDistr pd = PoolDistr { | ||
unPoolDistr = Map.map fromLedgerIndividualPoolStake $ SL.unPoolDistr pd | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
...onsensus-diffusion/changelog.d/20240618_100729_nick.frisby_cardano_node_8_12.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<!-- | ||
A new scriv changelog fragment. | ||
Uncomment the section that is right (remove the HTML comment wrapper). | ||
--> | ||
|
||
### Patch | ||
|
||
- Updated dependencies; no local changes required. | ||
|
||
<!-- | ||
### Non-Breaking | ||
- A bullet item for the Non-Breaking category. | ||
--> | ||
<!-- | ||
### Breaking | ||
- A bullet item for the Breaking category. | ||
--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.