-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add storage_proof_only
argument to RollupArgs
#13009
base: main
Are you sure you want to change the base?
Conversation
storage_proofs_only
to RollupArgs
storage_proof_only
argument to RollupArgs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some suggestions, directionally lgtm
crates/optimism/rpc/src/eth/mod.rs
Outdated
pub fn new( | ||
ctx: &EthApiBuilderCtx<N>, | ||
sequencer_http: Option<String>, | ||
storage_proof_only: Vec<Address>, | ||
) -> Self { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have a feeling we might need more settings in the future so we should change the way we configure this with some builder types for OpEthApi
and OpAddons
like
let api = OpEthApi::builder(ctx).with_sequencer().proof_only().build()
same for OpAddons
crates/optimism/rpc/src/eth/mod.rs
Outdated
@@ -67,6 +74,9 @@ pub struct OpEthApi<N: RpcNodeCore> { | |||
/// Sequencer client, configured to forward submitted transactions to sequencer of given OP | |||
/// network. | |||
sequencer_client: Option<SequencerClient>, | |||
/// List of addresses that _ONLY_ return storage proofs _WITHOUT_ an account proof when called | |||
/// with `eth_getProof`. | |||
storage_proof_only: Vec<Address>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should wrap all of those fields in a new Arced OpEthApiInner
type because this is cloned per request
Basically moved from odyssey, but without the need to replace the
http/auth
modulesAlso, adds
OpAddonsBuilder
andOpEthApiBuilder