diff --git a/cardano-testnet/changelog.d/20260226_005016_palas_default_to_update_timestamps.md b/cardano-testnet/changelog.d/20260226_005016_palas_default_to_update_timestamps.md new file mode 100644 index 00000000000..601ffd92964 --- /dev/null +++ b/cardano-testnet/changelog.d/20260226_005016_palas_default_to_update_timestamps.md @@ -0,0 +1,8 @@ +### Added + +- Added `--no-update-time` flag. + +### Changed + +- Made `--update-time` flag the default. + diff --git a/cardano-testnet/src/Parsers/Cardano.hs b/cardano-testnet/src/Parsers/Cardano.hs index d6797eb1ac4..fef2171a6d8 100644 --- a/cardano-testnet/src/Parsers/Cardano.hs +++ b/cardano-testnet/src/Parsers/Cardano.hs @@ -132,11 +132,14 @@ pMainnetParams = OA.flag' OnChainParamsMainnet ) pUpdateTimestamps :: Parser UpdateTimestamps -pUpdateTimestamps = OA.flag DontUpdateTimestamps UpdateTimestamps - ( OA.long "update-time" - <> OA.help "Update the time stamps in genesis files to current date" - <> OA.showDefault - ) +pUpdateTimestamps = + -- Default to UpdateTimestamps, because when using the two-step flow + -- (cardano-testnet create-env → cardano-testnet cardano --node-env), + -- genesis timestamps can become stale. + -- See https://github.com/IntersectMBO/cardano-node/issues/6455 + OA.flag' UpdateTimestamps (OA.long "update-time" <> OA.help "Update the time stamps in genesis files to current date (default, kept for backward compatibility)") + <|> OA.flag' DontUpdateTimestamps (OA.long "no-update-time" <> OA.help "Do not update the time stamps in genesis files to current date.") + <|> pure UpdateTimestamps pEnvOutputDir :: Parser FilePath pEnvOutputDir = OA.strOption diff --git a/cardano-testnet/test/cardano-testnet-golden/files/golden/help.cli b/cardano-testnet/test/cardano-testnet-golden/files/golden/help.cli index d3921a1cf8d..bac8219efac 100644 --- a/cardano-testnet/test/cardano-testnet-golden/files/golden/help.cli +++ b/cardano-testnet/test/cardano-testnet-golden/files/golden/help.cli @@ -12,7 +12,7 @@ Usage: cardano-testnet cardano [--num-pool-nodes COUNT] [--slot-length SECONDS] [--active-slots-coeff DOUBLE] [--node-env FILEPATH] - [--update-time] + [--update-time | --no-update-time] Start a testnet and keep it running until stopped diff --git a/cardano-testnet/test/cardano-testnet-golden/files/golden/help/cardano.cli b/cardano-testnet/test/cardano-testnet-golden/files/golden/help/cardano.cli index cc26e43d032..098999aa11c 100644 --- a/cardano-testnet/test/cardano-testnet-golden/files/golden/help/cardano.cli +++ b/cardano-testnet/test/cardano-testnet-golden/files/golden/help/cardano.cli @@ -10,7 +10,7 @@ Usage: cardano-testnet cardano [--num-pool-nodes COUNT] [--slot-length SECONDS] [--active-slots-coeff DOUBLE] [--node-env FILEPATH] - [--update-time] + [--update-time | --no-update-time] Start a testnet and keep it running until stopped @@ -51,5 +51,7 @@ Available options: with the 'create-env' command, then modify it and pass it with this argument. --update-time Update the time stamps in genesis files to current - date + date (default, kept for backward compatibility) + --no-update-time Do not update the time stamps in genesis files to + current date. -h,--help Show this help text