Skip to content

Reuse alloy-evm apply-state-overrides #11072

@mattsse

Description

@mattsse

Component

Anvil

Describe the feature you would like

same as #11071

but for

/// Applies the given state overrides to the given CacheDB
pub fn apply_state_overrides<D>(
overrides: StateOverride,
cache_db: &mut CacheDB<D>,
) -> Result<(), BlockchainError>
where
D: DatabaseRef<Error = DatabaseError>,
{

https://github.com/alloy-rs/evm/blob/666cb3bf0a6511e210e93b1d2e88d80fcf85708c/crates/evm/src/overrides.rs#L108-L120

for this we also need some additional error conversions for Blockchainerror

similar to

https://github.com/paradigmxyz/reth/blob/868c421c5d783c3a58a8fca77406a902b118baa4/crates/rpc/rpc-eth-types/src/error/mod.rs#L309-L324

see:

StateOverrideError(String),

maybe @Soubhik-10 ?

Additional context

No response

Metadata

Metadata

Assignees

Labels

C-anvilCommand: anvilT-featureType: featurefirst issueA good way to start contributing

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions