Rename Blob retention epoch flag (#13124)

* Rename flag and add alias

* Update cmd/beacon-chain/flags/base.go

Co-authored-by: Preston Van Loon <pvanloon@offchainlabs.com>

* Fix sentence

* Fix TestConfigureBlobRetentionEpoch

* Fix silly mistake

* Reviews

---------

Co-authored-by: Preston Van Loon <pvanloon@offchainlabs.com>
This commit is contained in:
Sammy Rosso
2023-10-30 18:35:31 +01:00
committed by GitHub
parent 159a5dd69d
commit 047613069e
2 changed files with 5 additions and 4 deletions

View File

@@ -35,5 +35,5 @@ func TestConfigureBlobRetentionEpoch(t *testing.T) {
require.NoError(t, set.Set(flags.BlobRetentionEpoch.Name, strconv.FormatUint(minEpochsForSidecarRequest-1, 10)))
cliCtx = cli.NewContext(&app, set, nil)
err := ConfigureBlobRetentionEpoch(cliCtx)
require.ErrorContains(t, "extend-blob-retention-epoch smaller than spec default", err)
require.ErrorContains(t, "blob-retention-epochs smaller than spec default", err)
}

View File

@@ -262,8 +262,9 @@ var (
Value: cmd.DefaultDataDir(),
}
BlobRetentionEpoch = &cli.Uint64Flag{
Name: "extend-blob-retention-epoch",
Usage: "Extend blob retention epoch period to beyond default 4096 epochs (~18 days). The node will error at start if input value is less than 4096 epochs.",
Value: uint64(params.BeaconNetworkConfig().MinEpochsForBlobsSidecarsRequest),
Name: "blob-retention-epochs",
Usage: "Override the default blob retention period (measured in epochs). The node will exit with an error at startup if the value is less than the default of 4096 epochs.",
Value: uint64(params.BeaconNetworkConfig().MinEpochsForBlobsSidecarsRequest),
Aliases: []string{"extend-blob-retention-epoch"},
}
)