-
Notifications
You must be signed in to change notification settings - Fork 90
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
Use traces to extract the input for settlement::Observer
#3233
Conversation
@@ -29,8 +29,6 @@ pub struct Settlement { | |||
gas: eth::Gas, | |||
/// The effective gas price of the settlement transaction. | |||
gas_price: eth::EffectiveGasPrice, | |||
/// The address of the solver that submitted the settlement transaction. | |||
solver: eth::Address, |
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.
Not strictly related to the task but removed for completeness, so we don't have to rethink how this field should be populated.
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.
Logic looks good to me.
The bit where the auction id gets spliced off the settle()
call might have to change in the future depending on the helper contracts. If the auction id gets appended to the overall function call the solidity logic of the helper contracts doesn't have to handle it at all which would probably result in gas savings. Not sure if those are big enough to matter in practice, though.
Refactored the error handling to notify more loudly if execution client bug is detected. Also, added the unit test to verify that |
Description
Implements first part of #3177
The expectation for "auction_id" remain the same:
auction_id
is expected at the end of the/settle
call/sub_call.Changes
trace_transaction
function to get traces and extract the calldata ofsettle
callHow to test
Existing tests show that no regression bugs were introduced.
Final e2e test should cover this part of the code. Although by manually testing the
trace_transaction
I am pretty sure the code is correct.