-
Notifications
You must be signed in to change notification settings - Fork 19
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
Add gas limit API #39
Conversation
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!
@michaelsproul haven't done an in-depth review of this PR's content but support the general idea Have you considered reworking/extending the existing suggested fee recipient endpoint to a more general validator preferences endpoint, rather than add (and then maintain) a separate endpoint per preference we may come across? I'd say if we only ever wanted to support the gas limit alongside the fee recipient then this is a moot point but you can see here ethereum/builder-specs#29 that there are other parameters consumers of the builder APIs may care about -- e.g. I could see adding support for |
@ralexstokes I think you're right that it would be better to have a consolidated endpoint for all of the parameters, but I was worried about deprecating the existing API so soon after it was introduced, and it's hard to update The alternative would be a new API endpoint that deprecates the feerecipient one and looks something like this:
All fields in In future we could add Pros and ConsAdvantages of new
|
at the time of discussing having a proposer_config vs individual APIs paul and I thought the specs mutated too much, at the end of the day it was asking the question of what benefits the end user ( who's typically using some UI to update) do we think the proposer config API will continue to change ( i think it will). I'd argue for different endpoints or for some endpoint specific to MEV/builder config. also question on the value of gas limit itself
I've always used the uint64 value and not the hex uint64 is there some reason for this? was something changed? |
we generally write uint64 values as strings to avoid issues w/ e.g. native JS numbers which are only 53 bits |
got it this makes sense now, from a user experience perspective a number seems fine even though it doesn't take advantage of the full 64 bit as the default is 30million, do you think it's required for the user to ever go above the 53bits? |
the gas limit as specified in the yellow paper is an arbitrary positive integer so in general it could go much higher than 30 million -- I would not take a snapshot of today as an "anchoring point" when this value could be much bigger in the future implementations should not special-case or cut corners on this as it means less maintenance burden over time, and the same thing applies to any sort of standard API we enshrine via this PR |
I'd at least argue for the sake of a better user experience that it's just a string number instead of a string hex. or at the very least take in both options with a casting error. |
I'd prefer we stick w/ the there we encode this as a @michaelsproul what do you think about updating this? or do you have another reason for electing u256? |
We went with updating specifically one field when Are we always likely to update both at once? If we're likely to want to update parts as 'optional' suggests, potentially keeping a separate API and just calling the one you want to update is a simpler flow. Then in the cases you do actually want to update both, you can call both apis... equally you can remove an attribute without affecting the other(s). If we do go with a larger configuration object plus having optional fields, using PATCH may be more analogous to what's actually going on. |
Side note while i remember - add to readme table :) |
How's this for a consensus decision?
Leave a 👍 react if you're happy with this, or comment with alternatives |
458a63d
to
5d5b2af
Compare
Awesome, I've updated this with the u64 gas limit, so I think it's ready for a final read-through and merge 🚀 |
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!
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
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!
Add a keymanager API for managing the gas limit.
Although several clients are standardising around a config file format shared by builders and validator clients (here: ethereum/builder-specs#41), I believe it's useful to have a separate push-based API for managing the gas limit, just as we have for fee recipients (further rationale here: flashbots/mev-boost#154 (comment)).