Skip to content

Commit

Permalink
Squashed
Browse files Browse the repository at this point in the history
  • Loading branch information
Jimbo4350 committed May 9, 2024
1 parent b8c8695 commit 2255c8e
Show file tree
Hide file tree
Showing 11 changed files with 79,850 additions and 35 deletions.
2 changes: 1 addition & 1 deletion bench/plutus-scripts-bench/plutus-scripts-bench.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ library
-- IOG dependencies
--------------------------
build-depends:
, cardano-api ^>= 8.44
, cardano-api ^>= 8.45.2.0
, plutus-ledger-api >=1.0.0
, plutus-tx >=1.0.0
, plutus-tx-plugin ^>=1.23
Expand Down
4 changes: 2 additions & 2 deletions bench/tx-generator/tx-generator.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,9 @@ library
, attoparsec-aeson
, base16-bytestring
, bytestring
, cardano-api ^>= 8.44
, cardano-api ^>= 8.45.2.0
, cardano-binary
, cardano-cli ^>= 8.22
, cardano-cli ^>= 8.23
, cardano-crypto-class
, cardano-crypto-wrapper
, cardano-data
Expand Down
23 changes: 19 additions & 4 deletions cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ repository cardano-haskell-packages
-- See CONTRIBUTING for information about these, including some Nix commands
-- you need to run if you change them
index-state:
, hackage.haskell.org 2024-03-26T06:28:59Z
, cardano-haskell-packages 2024-04-11T09:29:53Z
, hackage.haskell.org 2024-05-02T11:03:23Z
, cardano-haskell-packages 2024-05-03T12:56:13Z

packages:
cardano-node
Expand All @@ -31,8 +31,8 @@ packages:
trace-resources
trace-forward

program-options
ghc-options: -Werror
-- program-options
-- ghc-options: -Werror

test-show-details: direct

Expand All @@ -59,3 +59,18 @@ package plutus-scripts-bench
-- temporary! Please read the section in CONTRIBUTING about updating dependencies.

-- `smtp-mail` should depend on `crypton-connection` rather than `connection`!

source-repository-package
type: git
location: https://github.com/IntersectMBO/cardano-cli.git
tag: 5a68d53581c596f9eacbd87f91411a8bf5f875cf
subdir: cardano-cli


-- source-repository-package
-- type: git
-- location: https://github.com/IntersectMBO/cardano-api.git
-- tag: 98883f735368eb8ccafc9830ff350f77853d8d1c
-- subdir: cardano-api

allow-newer: ouroboros-consensus-diffusion
2 changes: 1 addition & 1 deletion cardano-node-chairman/cardano-node-chairman.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -88,5 +88,5 @@ test-suite chairman-tests
ghc-options: -threaded -rtsopts "-with-rtsopts=-N -T"

build-tool-depends: cardano-node:cardano-node
, cardano-cli:cardano-cli ^>= 8.22.0.0
, cardano-cli:cardano-cli ^>= 8.23.0.0
, cardano-node-chairman:cardano-node-chairman
2 changes: 1 addition & 1 deletion cardano-node/cardano-node.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ library
, async
, base16-bytestring
, bytestring
, cardano-api ^>= 8.44
, cardano-api ^>= 8.45.2.0
, cardano-crypto-class
, cardano-crypto-wrapper
, cardano-git-rev ^>=0.2.2
Expand Down
4 changes: 2 additions & 2 deletions cardano-submit-api/cardano-submit-api.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ library
, aeson
, async
, bytestring
, cardano-api ^>= 8.44
, cardano-api ^>= 8.45.2.0
, cardano-binary
, cardano-cli ^>= 8.22
, cardano-cli ^>= 8.23
, cardano-crypto-class ^>= 2.1.2
, http-media
, iohk-monitoring
Expand Down
7 changes: 4 additions & 3 deletions cardano-testnet/cardano-testnet.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ library
build-depends: aeson
, aeson-pretty
, ansi-terminal
, bytestring
, cardano-api ^>= 8.44
, cardano-cli ^>= 8.22
, bytestring
, cardano-api ^>= 8.45.2.0
, cardano-cli ^>= 8.23
, cardano-crypto-class
, cardano-crypto-wrapper
, cardano-git-rev ^>= 0.2.2
Expand Down Expand Up @@ -209,6 +209,7 @@ test-suite cardano-testnet-test
, cardano-api:{cardano-api, internal}
, cardano-cli
, cardano-crypto-class
, cardano-ledger-core
, cardano-ledger-conway
, cardano-ledger-core
, cardano-ledger-shelley
Expand Down
73 changes: 72 additions & 1 deletion cardano-testnet/src/Testnet/Defaults.hs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ module Testnet.Defaults
, defaultSpoColdKeyPair
, defaultShelleyGenesis
, defaultGenesisFilepath
, defaultV3CostModel
, defaultYamlHardforkViaConfig
, defaultMainnetTopology
, plutusV3NonSpendingScript
Expand Down Expand Up @@ -111,6 +112,76 @@ defaultAlonzoGenesis = do
Nothing -> Left $ AlonzoGenErrTooMuchPrecision r
Just s -> return s

maxTxExUnits = Api.toAlonzoExUnits
$ Api.ExecutionUnits
{ Api.executionSteps = 100000000000
, Api.executionMemory = 1400000000
}
maxBlockExUnits = Api.toAlonzoExUnits
$ Api.ExecutionUnits
{ Api.executionSteps = 20000000000
, Api.executionMemory = 62000000
}
apiCostModels =
let pv1 = Api.AnyPlutusScriptVersion Api.PlutusScriptV1
pv2 = Api.AnyPlutusScriptVersion Api.PlutusScriptV2
pv3 = Api.AnyPlutusScriptVersion Api.PlutusScriptV3
in mconcat [ Map.singleton pv1 defaultV1CostModel
, Map.singleton pv2 defaultV2CostModel
, Map.singleton pv3 defaultV3CostModel
]
defaultV1CostModel = Api.CostModel
[ 205665, 812, 1, 1, 1000, 571, 0, 1, 1000, 24177, 4, 1, 1000, 32, 117366, 102, 4
, 23000, 100, 23000, 100, 23000, 100, 23000, 100, 23000, 100, 23000, 100, 100, 100
, 23000, 100, 19537, 32, 175354, 32, 46417, 4, 221973, 511, 0, 1, 89141, 32, 497525
, 14068, 4, 2, 196500, 453240, 220, 0, 1, 1, 1000, 28662, 4, 2, 245000, 216773, 62
, 1, 1060367, 12586, 1, 208512, 421, 1, 187000, 1000, 52998, 1, 80436, 32, 43249, 32
, 1000, 32, 80556, 1, 57667, 4, 1000, 10, 197145, 156, 1, 197145, 156, 1, 204924, 473
, 1, 208896, 511, 1, 52467, 32, 64832, 32, 65493, 32, 22558, 32, 16563, 32, 76511, 32
, 196500, 453240, 220, 0, 1, 1, 69522, 11687, 0, 1, 60091, 32, 196500, 453240, 220, 0
, 1, 1, 196500, 453240, 220, 0, 1, 1, 806990, 30482, 4, 1927926, 82523, 4, 265318, 0
, 4, 0, 85931, 32, 205665, 812, 1, 1, 41182, 32, 212342, 32, 31220, 32, 32696, 32, 43357
, 32, 32247, 32, 38314, 32, 57996947, 18975, 10
]
defaultV2CostModel = Api.CostModel
[ 205665, 812, 1, 1, 1000, 571, 0, 1, 1000, 24177, 4, 1, 1000, 32, 117366, 10475, 4
, 23000, 100, 23000, 100, 23000, 100, 23000, 100, 23000, 100, 23000, 100, 100, 100
, 23000, 100, 19537, 32, 175354, 32, 46417, 4, 221973, 511, 0, 1, 89141, 32, 497525
, 14068, 4, 2, 196500, 453240, 220, 0, 1, 1, 1000, 28662, 4, 2, 245000, 216773, 62
, 1, 1060367, 12586, 1, 208512, 421, 1, 187000, 1000, 52998, 1, 80436, 32, 43249, 32
, 1000, 32, 80556, 1, 57667, 4, 1000, 10, 197145, 156, 1, 197145, 156, 1, 204924, 473
, 1, 208896, 511, 1, 52467, 32, 64832, 32, 65493, 32, 22558, 32, 16563, 32, 76511, 32
, 196500, 453240, 220, 0, 1, 1, 69522, 11687, 0, 1, 60091, 32, 196500, 453240, 220, 0
, 1, 1, 196500, 453240, 220, 0, 1, 1, 1159724, 392670, 0, 2, 806990, 30482, 4, 1927926
, 82523, 4, 265318, 0, 4, 0, 85931, 32, 205665, 812, 1, 1, 41182, 32, 212342, 32, 31220
, 32, 32696, 32, 43357, 32, 32247, 32, 38314, 32, 35892428, 10, 9462713, 1021, 10, 38887044
, 32947, 10
]


-- | Proposing script (protocol parameter update) fails to execute unless this is set to 0
cekStartupCost_exBudgetCPU :: Integer

Check warning on line 163 in cardano-testnet/src/Testnet/Defaults.hs

View workflow job for this annotation

GitHub Actions / build

Suggestion in cekStartupCost_exBudgetCPU in module Testnet.Defaults: Use camelCase ▫︎ Found: "cekStartupCost_exBudgetCPU :: Integer" ▫︎ Perhaps: "cekStartupCostExBudgetCPU :: Integer"
cekStartupCost_exBudgetCPU = 1

Check warning on line 164 in cardano-testnet/src/Testnet/Defaults.hs

View workflow job for this annotation

GitHub Actions / build

Suggestion in cekStartupCost_exBudgetCPU in module Testnet.Defaults: Use camelCase ▫︎ Found: "cekStartupCost_exBudgetCPU = ..." ▫︎ Perhaps: "cekStartupCostExBudgetCPU = ..."

cekLamCost_exBudgetMemory :: Integer

Check warning on line 166 in cardano-testnet/src/Testnet/Defaults.hs

View workflow job for this annotation

GitHub Actions / build

Suggestion in cekLamCost_exBudgetMemory in module Testnet.Defaults: Use camelCase ▫︎ Found: "cekLamCost_exBudgetMemory :: Integer" ▫︎ Perhaps: "cekLamCostExBudgetMemory :: Integer"
cekLamCost_exBudgetMemory = 1

Check warning on line 167 in cardano-testnet/src/Testnet/Defaults.hs

View workflow job for this annotation

GitHub Actions / build

Suggestion in cekLamCost_exBudgetMemory in module Testnet.Defaults: Use camelCase ▫︎ Found: "cekLamCost_exBudgetMemory = ..." ▫︎ Perhaps: "cekLamCostExBudgetMemory = ..."

defaultV3CostModel :: Api.CostModel
defaultV3CostModel = Api.CostModel
[ 205665, 812, 1, 1, 1000, 571, 0, 1, 1000, 24177, 4, 1, 1000, 32, 100, 10475, 4, 117366, 10475, 4, 103, 18
, 3209094, 6, 331451, 1, 65990684, 23097, 19, cekStartupCost_exBudgetCPU, cekLamCost_exBudgetMemory, 107
, 87060, 21, 16420089, 22, 2145798, 36, 3795345, 12, 889023, 1, 204237282, 23271, 36, 129165, 36, 189977790
, 85902, 36, 33012864, 36, 388443360, 1, 401885761, 72, 2331379, 72, 23000, 100, 23000, 100, 23000, 100, 23000, 100, 23000
, 100, 23000, 100, 23000, 100, 23000, 100, 100, 100, 23000, 100
, 19537, 32, 175354, 32, 46417, 4, 221973, 511, 0, 1, 89141, 32, 497525, 14068, 4, 2, 196500, 453240, 220, 0, 1, 1, 1000, 28662
, 4, 2, 245000, 216773, 62, 1, 1060367, 12586, 1, 208512, 421, 1, 187000, 1000, 52998, 1, 80436, 32
, 43249, 1000, 32, 32, 80556, 1, 57667, 4, 1927926, 82523, 4, 1000, 10, 197145, 156, 1, 197145, 156, 1, 204924, 473, 1, 208896
, 511, 1, 52467, 32, 64832, 32, 65493, 32, 22558, 32, 16563, 32, 76511, 32, 196500, 453240, 220, 0
, 1, 1, 69522, 11687, 0, 1, 60091, 32, 196500, 453240, 220, 0, 1, 1, 196500, 453240, 220, 0, 1, 1, 1159724, 392670, 0, 2, 806990
, 30482, 4, 1927926, 82523, 4, 265318, 0, 4, 0, 85931, 32, 205665, 812, 1, 1, 41182
, 32, 212342, 32, 31220, 32, 32696, 32, 43357, 32, 32247, 32, 38314, 32, 35190005, 10, 57996947, 18975, 10, 39121781, 32260, 10
]

defaultConwayGenesis :: ConwayGenesis StandardCrypto
defaultConwayGenesis =
let upPParams :: UpgradeConwayPParams Identity
Expand All @@ -120,7 +191,7 @@ defaultConwayGenesis =
, ucppCommitteeMinSize = 0
, ucppCommitteeMaxTermLength = EpochInterval 200
, ucppGovActionLifetime = EpochInterval 1 -- One Epoch
, ucppGovActionDeposit = Coin 1_000_000
, ucppGovActionDeposit = Coin 2_000_000
, ucppDRepDeposit = Coin 1_000_000
, ucppDRepActivity = EpochInterval 100
, ucppMinFeeRefScriptCostPerByte = 0 %! 1 -- FIXME GARBAGE VALUE
Expand Down

0 comments on commit 2255c8e

Please sign in to comment.