-
Notifications
You must be signed in to change notification settings - Fork 20.5k
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
cmd/geth: add flag --dev.gaslimit for dev mode #23686
Conversation
… gas limit in dev mode
Might it be sufficient to use |
Just tried - the gas limit does not seem to come up faster? Maybe I'm missing something else. Also the 1s pause between each block slows everything else down so even if it did I'm not sure it would be a net gain. I assume the recommended approach here is to roll my own genesis file? I guess that's not too bad but dev mode is otherwise pretty convenient.. Maybe an alternate take on this could be to initialize dev mode at --miner.gaslimit if it's set? |
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.
LGTM
Should we just bump the default gas limit to 30M in dev mode? |
We could do that, but I can see some value in being able to test arbitrarily gigantic blocks in devmode. I don't have a strong opinion though |
Just for some additional detail, I wanted to generate a large / complex fixture in eth state to run my test against and used this flag with a limit of 1B to complete the setup quickly. |
* cmd, core: add flag --dev.gaslimit to allow configuring initial block gas limit in dev mode * core: use provided gaslimit Co-authored-by: Martin Holst Swende <martin@swende.se>
* cmd, core: add flag --dev.gaslimit to allow configuring initial block gas limit in dev mode * core: use provided gaslimit Co-authored-by: Martin Holst Swende <martin@swende.se>
I was trying to tinker with some large gas limits to speed up some contract tests and while
--miner.gaslimit
does work, it takes a long time to reach if the initial gas limit is much lower.