diff --git a/op-node/flags/flags.go b/op-node/flags/flags.go index fa6fcd066db6..fef9f7b1582d 100644 --- a/op-node/flags/flags.go +++ b/op-node/flags/flags.go @@ -87,6 +87,7 @@ var ( Usage: "The L1 RethDB path, used to fetch receipts for L1 blocks. Only applicable when using the `reth_db` RPC kind with `l1.rpckind`.", EnvVars: prefixEnvVars("L1_RETHDB"), Required: false, + Hidden: true, } L1RPCRateLimit = &cli.Float64Flag{ Name: "l1.rpc-rate-limit", diff --git a/op-service/sources/receipts.go b/op-service/sources/receipts.go index f5520624a7f7..f3f5205ee457 100644 --- a/op-service/sources/receipts.go +++ b/op-service/sources/receipts.go @@ -138,9 +138,13 @@ var RPCProviderKinds = []RPCProviderKind{ RPCKindBasic, RPCKindAny, RPCKindStandard, - RPCKindRethDB, } +// Copy of RPCProviderKinds with RethDB added to all RethDB to be used but to hide it from the flags +var validRPCProviderKinds = func() []RPCProviderKind { + return append(RPCProviderKinds, RPCKindRethDB) +}() + func (kind RPCProviderKind) String() string { return string(kind) } @@ -159,7 +163,7 @@ func (kind *RPCProviderKind) Clone() any { } func ValidRPCProviderKind(value RPCProviderKind) bool { - for _, k := range RPCProviderKinds { + for _, k := range validRPCProviderKinds { if k == value { return true }