File tree Expand file tree Collapse file tree 3 files changed +6
-3
lines changed
proto/utxorpc/v1alpha/cardano
src/Cardano/Rpc/Server/Internal Expand file tree Collapse file tree 3 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -33,14 +33,14 @@ message MultiAsset {
3333}
3434
3535// Represents a script in Cardano.
36- // TODO u5c: removed native script representation
36+ // TODO u5c: removed native script representation, added plutus_v4
3737message Script {
3838 oneof script {
3939 bytes native = 1 ; // Native script.
4040 bytes plutus_v1 = 2 ; // Plutus V1 script.
4141 bytes plutus_v2 = 3 ; // Plutus V2 script.
4242 bytes plutus_v3 = 4 ; // Plutus V3 script.
43- bytes plutus_v4 = 5 ; // Plutus V3 script.
43+ bytes plutus_v4 = 5 ; // Plutus V4 script.
4444 }
4545}
4646
@@ -77,6 +77,7 @@ message CostModels {
7777 CostModel plutus_v1 = 1 ;
7878 CostModel plutus_v2 = 2 ;
7979 CostModel plutus_v3 = 3 ;
80+ CostModel plutus_v4 = 4 ;
8081}
8182
8283message VotingThresholds {
Original file line number Diff line number Diff line change @@ -163,6 +163,7 @@ instance L.ConwayEraPParams lera => Inject (L.PParams lera) (Proto UtxoRpc.PPara
163163 & # costModels . # plutusV1 . # values .~ (join . maybeToList) (M. lookup L. PlutusV1 pparamsCostModels)
164164 & # costModels . # plutusV2 . # values .~ (join . maybeToList) (M. lookup L. PlutusV2 pparamsCostModels)
165165 & # costModels . # plutusV3 . # values .~ (join . maybeToList) (M. lookup L. PlutusV3 pparamsCostModels)
166+ & # costModels . # plutusV4 . # values .~ (join . maybeToList) (M. lookup L. PlutusV4 pparamsCostModels)
166167 & # prices . # steps .~ pparams ^. L. ppPricesL . to L. prSteps . to L. unboundRational . to inject
167168 & # prices . # memory .~ pparams ^. L. ppPricesL . to L. prMem . to L. unboundRational . to inject
168169 & # maxExecutionUnitsPerTransaction .~ pparams ^. L. ppMaxTxExUnitsL . to inject
Original file line number Diff line number Diff line change @@ -83,9 +83,10 @@ utxoRpcPParamsToProtocolParams era pp = conwayEraOnwardsConstraints (convert era
8383 cm1 <- L. mkCostModel L. PlutusV1 $ pp ^. # costModels . # plutusV1 . # values
8484 cm2 <- L. mkCostModel L. PlutusV2 $ pp ^. # costModels . # plutusV2 . # values
8585 cm3 <- L. mkCostModel L. PlutusV3 $ pp ^. # costModels . # plutusV3 . # values
86+ cm4 <- L. mkCostModel L. PlutusV4 $ pp ^. # costModels . # plutusV4 . # values
8687 -- do not add empty cost models
8788 let nonEmptyCostModels =
88- fromList . flip mapMaybe [cm1, cm2, cm3] $ \ cm ->
89+ fromList . flip mapMaybe [cm1, cm2, cm3, cm4 ] $ \ cm ->
8990 if not (null $ L. getCostModelParams cm)
9091 then Just (L. getCostModelLanguage cm, cm)
9192 else Nothing
You can’t perform that action at this time.
0 commit comments