From 3fe3e9c54499b1f2ebce3934baeef6e10de4ad29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Hurlin?= Date: Thu, 14 Nov 2024 17:00:08 +0100 Subject: [PATCH 1/2] create-testnet-data: use experimental API and tighten arguments so that they are era specific --- .../src/Cardano/CLI/EraBased/Commands/Genesis.hs | 14 ++++++++++---- .../src/Cardano/CLI/EraBased/Options/Genesis.hs | 11 ++++++----- .../CLI/EraBased/Run/Genesis/CreateTestnetData.hs | 10 ++++++---- 3 files changed, 22 insertions(+), 13 deletions(-) diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Commands/Genesis.hs b/cardano-cli/src/Cardano/CLI/EraBased/Commands/Genesis.hs index 50410f3da0..bea18c357a 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Commands/Genesis.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Commands/Genesis.hs @@ -1,5 +1,6 @@ {-# LANGUAGE DataKinds #-} {-# LANGUAGE DuplicateRecordFields #-} +{-# LANGUAGE ExistentialQuantification #-} {-# LANGUAGE LambdaCase #-} module Cardano.CLI.EraBased.Commands.Genesis @@ -19,6 +20,7 @@ module Cardano.CLI.EraBased.Commands.Genesis where import qualified Cardano.Api.Byron as Byron +import qualified Cardano.Api.Experimental as Exp import Cardano.Api.Ledger (Coin) import Cardano.Api.Shelley @@ -30,7 +32,7 @@ data GenesisCmds era = GenesisCreate !(GenesisCreateCmdArgs era) | GenesisCreateCardano !(GenesisCreateCardanoCmdArgs era) | GenesisCreateStaked !(GenesisCreateStakedCmdArgs era) - | GenesisCreateTestNetData !(GenesisCreateTestNetDataCmdArgs era) + | GenesisCreateTestNetData !GenesisCreateTestNetDataCmdArgs | GenesisKeyGenGenesis !GenesisKeyGenGenesisCmdArgs | GenesisKeyGenDelegate !GenesisKeyGenDelegateCmdArgs | GenesisKeyGenUTxO !GenesisKeyGenUTxOCmdArgs @@ -92,8 +94,10 @@ data GenesisCreateStakedCmdArgs era = GenesisCreateStakedCmdArgs } deriving Show -data GenesisCreateTestNetDataCmdArgs era = GenesisCreateTestNetDataCmdArgs - { eon :: !(ShelleyBasedEra era) +-- TODO This existential type parameter should become a regular type parameter +-- when we parameterize the parent type by the experimental era API. +data GenesisCreateTestNetDataCmdArgs = forall era. GenesisCreateTestNetDataCmdArgs + { eon :: !(Exp.Era era) , specShelley :: !(Maybe FilePath) -- ^ Path to the @genesis-shelley@ file to use. If unspecified, a default one will be used. , specAlonzo :: !(Maybe FilePath) @@ -127,7 +131,9 @@ data GenesisCreateTestNetDataCmdArgs era = GenesisCreateTestNetDataCmdArgs , outputDir :: !FilePath -- ^ Directory where to write credentials and files. } - deriving Show + +instance Show GenesisCreateTestNetDataCmdArgs where + show _ = "GenesisCreateTestNetDataCmdArgs" data GenesisKeyGenGenesisCmdArgs = GenesisKeyGenGenesisCmdArgs { verificationKeyPath :: !(VerificationKeyFile Out) diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Options/Genesis.hs b/cardano-cli/src/Cardano/CLI/EraBased/Options/Genesis.hs index f6e749b04a..c920276eb3 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Options/Genesis.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Options/Genesis.hs @@ -11,6 +11,7 @@ where import Cardano.Api hiding (QueryInShelleyBasedEra (..)) import qualified Cardano.Api.Byron as Byron +import qualified Cardano.Api.Experimental as Exp import Cardano.Api.Ledger (Coin (..)) import Cardano.CLI.Environment (EnvCli (..)) @@ -217,18 +218,18 @@ pGenesisCreateStaked sbe envCli = pRelayJsonFp = parseFilePath "relay-specification-file" "JSON file that specifies the relays of each stake pool." -pGenesisCreateTestNetData :: ShelleyBasedEra era -> EnvCli -> Parser (GenesisCmds era) -pGenesisCreateTestNetData sbe envCli = +pGenesisCreateTestNetData :: Exp.Era era -> EnvCli -> Parser (GenesisCmds era) +pGenesisCreateTestNetData era envCli = fmap GenesisCreateTestNetData $ - GenesisCreateTestNetDataCmdArgs sbe + GenesisCreateTestNetDataCmdArgs era <$> optional (pSpecFile "shelley") <*> optional (pSpecFile "alonzo") <*> optional (pSpecFile "conway") <*> pNumGenesisKeys <*> pNumPools <*> pNumStakeDelegs - <*> pNumCommittee - <*> pNumDReps + <*> (case era of Exp.BabbageEra -> pure 0; Exp.ConwayEra -> pNumCommittee) -- Committee doesn't exist in babbage + <*> (case era of Exp.BabbageEra -> pure $ DRepCredentials OnDisk 0; Exp.ConwayEra -> pNumDReps) -- DReps don't exist in babbage <*> pNumStuffedUtxoCount <*> pNumUtxoKeys <*> pSupply diff --git a/cardano-cli/src/Cardano/CLI/EraBased/Run/Genesis/CreateTestnetData.hs b/cardano-cli/src/Cardano/CLI/EraBased/Run/Genesis/CreateTestnetData.hs index 60cb81d9bd..c3fa8ecd2d 100644 --- a/cardano-cli/src/Cardano/CLI/EraBased/Run/Genesis/CreateTestnetData.hs +++ b/cardano-cli/src/Cardano/CLI/EraBased/Run/Genesis/CreateTestnetData.hs @@ -208,7 +208,7 @@ data WriteFileGenesis where WritePretty :: ToJSON genesis => genesis -> WriteFileGenesis runGenesisCreateTestNetDataCmd - :: GenesisCreateTestNetDataCmdArgs era + :: GenesisCreateTestNetDataCmdArgs -> ExceptT GenesisCmdError IO () runGenesisCreateTestNetDataCmd Cmd.GenesisCreateTestNetDataCmdArgs @@ -239,7 +239,7 @@ runGenesisCreateTestNetDataCmd , outputDir } = do liftIO $ createDirectoryIfMissing False outputDir - let era = toCardanoEra eon + let era = convert eon shelleyGenesisInit <- fromMaybe shelleyGenesisDefaults <$> traverse decodeShelleyGenesisFile specShelley alonzoGenesis <- @@ -298,7 +298,8 @@ runGenesisCreateTestNetDataCmd when (0 < numPools) $ writeREADME poolsDir poolsREADME - -- CC members + -- CC members. We don't need to look at the eon, because the command's parser guarantees + -- that before Conway, the number of CC members at this point is 0. ccColdKeys <- forM [1 .. numCommitteeKeys] $ \index -> do let committeeDir = committeesDir "cc" <> show index vkeyHotFile = File @(VerificationKey ()) $ committeeDir "cc.hot.vkey" @@ -318,7 +319,8 @@ runGenesisCreateTestNetDataCmd when (0 < numCommitteeKeys) $ writeREADME committeesDir committeeREADME - -- DReps + -- DReps. We don't need to look at the eon, because the command's parser guarantees + -- that before Conway, the number of DReps at this point is 0. g <- Random.getStdGen dRepKeys <- firstExceptT GenesisCmdFileError $ From 7db283b1eff02c984404616dc34e5aa3d0ab684d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Hurlin?= Date: Thu, 14 Nov 2024 17:10:28 +0100 Subject: [PATCH 2/2] Adapt golden files --- .../cardano-cli-golden/files/golden/help.cli | 100 ------------------ .../files/golden/help/allegra_genesis.cli | 2 - .../allegra_genesis_create-testnet-data.cli | 69 ------------ .../files/golden/help/alonzo_genesis.cli | 2 - .../alonzo_genesis_create-testnet-data.cli | 69 ------------ .../babbage_genesis_create-testnet-data.cli | 11 -- .../files/golden/help/mary_genesis.cli | 2 - .../help/mary_genesis_create-testnet-data.cli | 69 ------------ .../files/golden/help/shelley_genesis.cli | 2 - .../shelley_genesis_create-testnet-data.cli | 69 ------------ 10 files changed, 395 deletions(-) delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis_create-testnet-data.cli delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis_create-testnet-data.cli delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis_create-testnet-data.cli delete mode 100644 cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis_create-testnet-data.cli diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help.cli index 0c477abe61..0aac0a2b8e 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help.cli @@ -1094,7 +1094,6 @@ Usage: cardano-cli shelley genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -1194,29 +1193,6 @@ Usage: cardano-cli shelley genesis create-staked [--key-output-format STRING] Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. -Usage: cardano-cli shelley genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - Usage: cardano-cli shelley genesis hash --genesis FILEPATH Compute the hash of a genesis file @@ -2167,7 +2143,6 @@ Usage: cardano-cli allegra genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -2267,29 +2242,6 @@ Usage: cardano-cli allegra genesis create-staked [--key-output-format STRING] Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. -Usage: cardano-cli allegra genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - Usage: cardano-cli allegra genesis hash --genesis FILEPATH Compute the hash of a genesis file @@ -3240,7 +3192,6 @@ Usage: cardano-cli mary genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -3338,29 +3289,6 @@ Usage: cardano-cli mary genesis create-staked [--key-output-format STRING] Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. -Usage: cardano-cli mary genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - Usage: cardano-cli mary genesis hash --genesis FILEPATH Compute the hash of a genesis file @@ -4303,7 +4231,6 @@ Usage: cardano-cli alonzo genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -4401,29 +4328,6 @@ Usage: cardano-cli alonzo genesis create-staked [--key-output-format STRING] Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. -Usage: cardano-cli alonzo genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - Usage: cardano-cli alonzo genesis hash --genesis FILEPATH Compute the hash of a genesis file @@ -5489,10 +5393,6 @@ Usage: cardano-cli babbage genesis create-testnet-data [--spec-shelley FILEPATH] [ --stake-delegators INT | --transient-stake-delegators INT ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] [--stuffed-utxo INT] [--utxo-keys INT] [--total-supply LOVELACE] diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis.cli index 26ad5f21ba..8b10843c12 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis.cli @@ -9,7 +9,6 @@ Usage: cardano-cli allegra genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -35,5 +34,4 @@ Available commands: and genesis/delegation/spending keys. create-staked Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. - create-testnet-data Create data to use for starting a testnet. hash Compute the hash of a genesis file diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis_create-testnet-data.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis_create-testnet-data.cli deleted file mode 100644 index 46ab77f9c7..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/allegra_genesis_create-testnet-data.cli +++ /dev/null @@ -1,69 +0,0 @@ -Usage: cardano-cli allegra genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - -Available options: - --spec-shelley FILEPATH The shelley specification file to use as input. A - default one is generated if omitted. - --spec-alonzo FILEPATH The alonzo specification file to use as input. A - default one is generated if omitted. - --spec-conway FILEPATH The conway specification file to use as input. A - default one is generated if omitted. - --genesis-keys INT The number of genesis keys to make (default is 3). - --pools INT The number of stake pool credential sets to make - (default is 0). - --stake-delegators INT The number of stake delegator credential sets to make - (default is 0). Credentials are written to disk. - --transient-stake-delegators INT - The number of stake delegator credential sets to make - (default is 0). The credentials are NOT written to - disk. - --committee-keys INT The number of constitutional committee credentials to - make (default is 0). - --drep-keys INT The number of DRep credentials to make (default is - 0). Credentials are written to disk. - --transient-drep-keys INT - The number of DRep credentials to make (default is - 0). The credentials are NOT written to disk. - --stuffed-utxo INT The number of fake UTxO entries to generate (default - is 0). - --utxo-keys INT The number of UTxO keys to make (default is 0). - --total-supply LOVELACE The maximum possible amount of Lovelace, which is - evenly distributed across stake holders. Overrides - the value from the shelley genesis. If - --delegated-supply is specified, a part of this - amount will be delegated. - --delegated-supply LOVELACE - The amount of the total supply which is evenly - delegated. Defaulted to half of the total supply. - Cannot be more than the amount specified with - --total-supply. - --testnet-magic NATURAL Specify a testnet magic id for the cluster. This - overrides both the network magic from the spec file - and CARDANO_NODE_NETWORK_ID environment variable. - --relays FILEPATH JSON file specifying the relays of each stake pool. - --start-time UTC-TIME The genesis start time in YYYY-MM-DDThh:mm:ssZ - format. If unspecified, will be the current time +30 - seconds. - --out-dir DIR The directory where to generate the data. Created if - not existing. - -h,--help Show this help text diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis.cli index ae53c4c925..a1d6c67f4e 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis.cli @@ -9,7 +9,6 @@ Usage: cardano-cli alonzo genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -35,5 +34,4 @@ Available commands: and genesis/delegation/spending keys. create-staked Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. - create-testnet-data Create data to use for starting a testnet. hash Compute the hash of a genesis file diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis_create-testnet-data.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis_create-testnet-data.cli deleted file mode 100644 index 4673b3c135..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/alonzo_genesis_create-testnet-data.cli +++ /dev/null @@ -1,69 +0,0 @@ -Usage: cardano-cli alonzo genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - -Available options: - --spec-shelley FILEPATH The shelley specification file to use as input. A - default one is generated if omitted. - --spec-alonzo FILEPATH The alonzo specification file to use as input. A - default one is generated if omitted. - --spec-conway FILEPATH The conway specification file to use as input. A - default one is generated if omitted. - --genesis-keys INT The number of genesis keys to make (default is 3). - --pools INT The number of stake pool credential sets to make - (default is 0). - --stake-delegators INT The number of stake delegator credential sets to make - (default is 0). Credentials are written to disk. - --transient-stake-delegators INT - The number of stake delegator credential sets to make - (default is 0). The credentials are NOT written to - disk. - --committee-keys INT The number of constitutional committee credentials to - make (default is 0). - --drep-keys INT The number of DRep credentials to make (default is - 0). Credentials are written to disk. - --transient-drep-keys INT - The number of DRep credentials to make (default is - 0). The credentials are NOT written to disk. - --stuffed-utxo INT The number of fake UTxO entries to generate (default - is 0). - --utxo-keys INT The number of UTxO keys to make (default is 0). - --total-supply LOVELACE The maximum possible amount of Lovelace, which is - evenly distributed across stake holders. Overrides - the value from the shelley genesis. If - --delegated-supply is specified, a part of this - amount will be delegated. - --delegated-supply LOVELACE - The amount of the total supply which is evenly - delegated. Defaulted to half of the total supply. - Cannot be more than the amount specified with - --total-supply. - --testnet-magic NATURAL Specify a testnet magic id for the cluster. This - overrides both the network magic from the spec file - and CARDANO_NODE_NETWORK_ID environment variable. - --relays FILEPATH JSON file specifying the relays of each stake pool. - --start-time UTC-TIME The genesis start time in YYYY-MM-DDThh:mm:ssZ - format. If unspecified, will be the current time +30 - seconds. - --out-dir DIR The directory where to generate the data. Created if - not existing. - -h,--help Show this help text diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/babbage_genesis_create-testnet-data.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/babbage_genesis_create-testnet-data.cli index 0c3619bdd4..29a821b1da 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/babbage_genesis_create-testnet-data.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/babbage_genesis_create-testnet-data.cli @@ -6,10 +6,6 @@ Usage: cardano-cli babbage genesis create-testnet-data [--spec-shelley FILEPATH] [ --stake-delegators INT | --transient-stake-delegators INT ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] [--stuffed-utxo INT] [--utxo-keys INT] [--total-supply LOVELACE] @@ -37,13 +33,6 @@ Available options: The number of stake delegator credential sets to make (default is 0). The credentials are NOT written to disk. - --committee-keys INT The number of constitutional committee credentials to - make (default is 0). - --drep-keys INT The number of DRep credentials to make (default is - 0). Credentials are written to disk. - --transient-drep-keys INT - The number of DRep credentials to make (default is - 0). The credentials are NOT written to disk. --stuffed-utxo INT The number of fake UTxO entries to generate (default is 0). --utxo-keys INT The number of UTxO keys to make (default is 0). diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis.cli index a833fbfedf..95034b1ccf 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis.cli @@ -9,7 +9,6 @@ Usage: cardano-cli mary genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -35,5 +34,4 @@ Available commands: and genesis/delegation/spending keys. create-staked Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. - create-testnet-data Create data to use for starting a testnet. hash Compute the hash of a genesis file diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis_create-testnet-data.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis_create-testnet-data.cli deleted file mode 100644 index 7ecfe83700..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/mary_genesis_create-testnet-data.cli +++ /dev/null @@ -1,69 +0,0 @@ -Usage: cardano-cli mary genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - -Available options: - --spec-shelley FILEPATH The shelley specification file to use as input. A - default one is generated if omitted. - --spec-alonzo FILEPATH The alonzo specification file to use as input. A - default one is generated if omitted. - --spec-conway FILEPATH The conway specification file to use as input. A - default one is generated if omitted. - --genesis-keys INT The number of genesis keys to make (default is 3). - --pools INT The number of stake pool credential sets to make - (default is 0). - --stake-delegators INT The number of stake delegator credential sets to make - (default is 0). Credentials are written to disk. - --transient-stake-delegators INT - The number of stake delegator credential sets to make - (default is 0). The credentials are NOT written to - disk. - --committee-keys INT The number of constitutional committee credentials to - make (default is 0). - --drep-keys INT The number of DRep credentials to make (default is - 0). Credentials are written to disk. - --transient-drep-keys INT - The number of DRep credentials to make (default is - 0). The credentials are NOT written to disk. - --stuffed-utxo INT The number of fake UTxO entries to generate (default - is 0). - --utxo-keys INT The number of UTxO keys to make (default is 0). - --total-supply LOVELACE The maximum possible amount of Lovelace, which is - evenly distributed across stake holders. Overrides - the value from the shelley genesis. If - --delegated-supply is specified, a part of this - amount will be delegated. - --delegated-supply LOVELACE - The amount of the total supply which is evenly - delegated. Defaulted to half of the total supply. - Cannot be more than the amount specified with - --total-supply. - --testnet-magic NATURAL Specify a testnet magic id for the cluster. This - overrides both the network magic from the spec file - and CARDANO_NODE_NETWORK_ID environment variable. - --relays FILEPATH JSON file specifying the relays of each stake pool. - --start-time UTC-TIME The genesis start time in YYYY-MM-DDThh:mm:ssZ - format. If unspecified, will be the current time +30 - seconds. - --out-dir DIR The directory where to generate the data. Created if - not existing. - -h,--help Show this help text diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis.cli index 4ddff5f8c0..65ff660ac0 100644 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis.cli +++ b/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis.cli @@ -9,7 +9,6 @@ Usage: cardano-cli shelley genesis | create-cardano | create | create-staked - | create-testnet-data | hash ) @@ -35,5 +34,4 @@ Available commands: and genesis/delegation/spending keys. create-staked Create a staked Shelley genesis file from a genesis template and genesis/delegation/spending keys. - create-testnet-data Create data to use for starting a testnet. hash Compute the hash of a genesis file diff --git a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis_create-testnet-data.cli b/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis_create-testnet-data.cli deleted file mode 100644 index 6acb078b35..0000000000 --- a/cardano-cli/test/cardano-cli-golden/files/golden/help/shelley_genesis_create-testnet-data.cli +++ /dev/null @@ -1,69 +0,0 @@ -Usage: cardano-cli shelley genesis create-testnet-data [--spec-shelley FILEPATH] - [--spec-alonzo FILEPATH] - [--spec-conway FILEPATH] - [--genesis-keys INT] - [--pools INT] - [ --stake-delegators INT - | --transient-stake-delegators INT - ] - [--committee-keys INT] - [ --drep-keys INT - | --transient-drep-keys INT - ] - [--stuffed-utxo INT] - [--utxo-keys INT] - [--total-supply LOVELACE] - [--delegated-supply LOVELACE] - [--testnet-magic NATURAL] - [--relays FILEPATH] - [--start-time UTC-TIME] - --out-dir DIR - - Create data to use for starting a testnet. - -Available options: - --spec-shelley FILEPATH The shelley specification file to use as input. A - default one is generated if omitted. - --spec-alonzo FILEPATH The alonzo specification file to use as input. A - default one is generated if omitted. - --spec-conway FILEPATH The conway specification file to use as input. A - default one is generated if omitted. - --genesis-keys INT The number of genesis keys to make (default is 3). - --pools INT The number of stake pool credential sets to make - (default is 0). - --stake-delegators INT The number of stake delegator credential sets to make - (default is 0). Credentials are written to disk. - --transient-stake-delegators INT - The number of stake delegator credential sets to make - (default is 0). The credentials are NOT written to - disk. - --committee-keys INT The number of constitutional committee credentials to - make (default is 0). - --drep-keys INT The number of DRep credentials to make (default is - 0). Credentials are written to disk. - --transient-drep-keys INT - The number of DRep credentials to make (default is - 0). The credentials are NOT written to disk. - --stuffed-utxo INT The number of fake UTxO entries to generate (default - is 0). - --utxo-keys INT The number of UTxO keys to make (default is 0). - --total-supply LOVELACE The maximum possible amount of Lovelace, which is - evenly distributed across stake holders. Overrides - the value from the shelley genesis. If - --delegated-supply is specified, a part of this - amount will be delegated. - --delegated-supply LOVELACE - The amount of the total supply which is evenly - delegated. Defaulted to half of the total supply. - Cannot be more than the amount specified with - --total-supply. - --testnet-magic NATURAL Specify a testnet magic id for the cluster. This - overrides both the network magic from the spec file - and CARDANO_NODE_NETWORK_ID environment variable. - --relays FILEPATH JSON file specifying the relays of each stake pool. - --start-time UTC-TIME The genesis start time in YYYY-MM-DDThh:mm:ssZ - format. If unspecified, will be the current time +30 - seconds. - --out-dir DIR The directory where to generate the data. Created if - not existing. - -h,--help Show this help text