foundry-rs / foundry-rs/foundry

feat(`anvil`): `--compute-units-per-second` should not be ignored on local Anvil fork

Open
#9,821 1 comment 0 reactions 0 assignees View on GitHub
C-anvil T-feature
Dominant language
Rust
Stars
10.6k
Forks
2.6k
Avg merge
18h 20m
Merged PRs (30d)
510

Description

Running an anvil fork as follows:

```bash
anvil --version
# anvil 0.2.0 (e5dbb7a 2024-12-03T00:24:42.571016376Z)
anvil -f $ALCHEMY_URL --compute-units-per-second 100
```

And launching a fork test on it as follows:
```bash
forge --version
# forge 0.2.0 (e5dbb7a 2024-12-03T00:24:42.577356416Z)
forge test --rpc-url=http://localhost:8545 --compute-units-per-second 100
```

Seems to ignore the CUPS value.
The problem is even more visible when the fork is created against a more heavily rate-limited RPC where even with a CUPS value of 1, the fork quickly gets 429 errors and the *request logs show no sign of throttling*

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.