-
Notifications
You must be signed in to change notification settings - Fork 5.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
EIP1559: import original min gas limit #3560
EIP1559: import original min gas limit #3560
Conversation
Another thing to note: The original rules (which can be seen in the screenshot above), used the
Whereas EIP-1559, as currently writen, uses:
I didn't notice this until now, and I suspect that the same oversight may be present in other implementations. |
Ouch that's a good spot, I didn't notice this myself either! 😄 |
Should we change this so it matches the YP again? |
I have no strong opinion in that matter. However, I do have a strong opinion on getting clients to agree. Here are some test vectors for how geth is currently implemented (afaict according to the spec as written): Would be neat if other implementors checked those same exact cases. They test both the exact limit, and exceeding the limit, up aswell as down. |
If it turns out that most clients have it the other (original) way, I think I'd prefer to use that. It's slightly simpler, because the flooring doesn't matter. EDIT: The fact that we divide the gaslimit by |
I think we should go for the original way, because this change somewhat increases code complexity. |
Same testcases, but in table-form:
|
thanks for that. Do you have some testcases when it it is the INITIAL_FORK_BLOCK_NUMBER ? |
In the first table, |
For OE original way also has lower code complexity. |
So, I think operating on the gasTarget at this point is a leftover. The spec did it because the header exposed gasTarget instead of gasLimit, but once we reverted to using the limit, we should revert everywhere. It keeps things simple and consistent. |
I agree. I'll open a new PR |
Suggestion:#3566 |
@vbuterin please approve this one too, my PR which got merged was intended to be in conjunction with this one. |
but @jochem-brouwer perhaps you need to rebase it now (sorry!) |
0f1b08e
to
71737bb
Compare
@holiman No problem, rebased upon master 😄 |
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.
Looks good to me
Current spec seems to indicate we remove the min gas limit (see Yellow Paper reference):
This PR fixes this as removing the min gas limit is not desired.