foundry-rs / foundry-rs/foundry
Better Hardfork -> evm SpecId handling for L2s
- Dominant language
- Rust
- Stars
- 10.6k
- Forks
- 2.6k
- Avg merge
- 18h 20m
- Merged PRs (30d)
- 510
Description
### Component
Anvil
### Describe the feature you would like
currently the Hardfork to specid conversion is only handled properly for mainnet
https://github.com/foundry-rs/foundry/blob/64320313edd81795751b8ec61d3cdcb35e419ce9/crates/anvil/src/config.rs#L805-L805
if no hardfork argument is provided:
https://github.com/foundry-rs/foundry/blob/64320313edd81795751b8ec61d3cdcb35e419ce9/crates/anvil/src/config.rs#L940-L941
we can make this smarter if we have hardfork/specid heights for L2s
## TODO
gather hardfork to evm specid blockheights for commonly used L2s/networks
* polygon
* OP
* Arbitrum
* ...
### Additional context
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.