Skip to content

Conversation

@colinlyguo
Copy link
Contributor

@colinlyguo colinlyguo commented Feb 17, 2025

This PR adds the AuthList field in toCallArg to support eth_call and eth_estimateGas of SetCodeTx.

Some unit tests are added in this PR (containing uncovered cases, e.g., ErrSetCodeTxCreate).

@fjl
Copy link
Contributor

fjl commented Feb 17, 2025

We have been discussing this. At the moment, it doesn't feel very useful since you need a signed authorization in order to invoke the call. It's not super convenient. And it's not really necessary to override an account with code via EIP-7702 in eth_call because it already supports arbitrary state overrides in Geth. And the new method eth_simulateV1 supports overrides in all clients.

@colinlyguo
Copy link
Contributor Author

colinlyguo commented Feb 17, 2025

We have been discussing this. At the moment, it doesn't feel very useful since you need a signed authorization in order to invoke the call. It's not super convenient. And it's not really necessary to override an account with code via EIP-7702 in eth_call because it already supports arbitrary state overrides in Geth. And the new method eth_simulateV1 supports overrides in all clients.

aha. I see and thanks. IMHO the main intention for this PR is not to overwrite accounts but to return an accurate gas estimation. e.g. bundlers may need to estimate gas (if the bundle transactions have some delegation submissions. I learned this from here. Though they might be written in other languages, too). In the meantime, it doesn't make it worse to support AuthList here, haven't thought of any side effects.

btw, do you think the added unit tests are useful here? might tweak some if duplicated.

@s1na s1na changed the title client: add AuthList field in toCallArg ethclient: add AuthList field in toCallArg Feb 18, 2025
@colinlyguo colinlyguo requested a review from s1na February 24, 2025 12:20
@colinlyguo
Copy link
Contributor Author

added some small fixes, pls take a look again. cc @fjl @s1na

@buddh0
Copy link
Contributor

buddh0 commented Mar 7, 2025

I think it's an useful feature

@colinlyguo
Copy link
Contributor Author

colinlyguo commented Mar 14, 2025

Asking for reviews (maybe further updates are needed or some things are unnecessary?). @s1na @fjl

@clabby
Copy link

clabby commented Mar 25, 2025

What's the status here? This is useful to have - we've resorted to a shim above eth_estimateGas to manually include auth list costs in the meantime.

@colinlyguo
Copy link
Contributor Author

bump. @s1na @fjl

s1na
s1na previously approved these changes Apr 17, 2025
Copy link
Contributor

@s1na s1na left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@s1na
Copy link
Contributor

s1na commented Apr 23, 2025

Renamed the field to AuthorizationList to keep it consistent with the API field.

Copy link
Contributor

@s1na s1na left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@s1na s1na added this to the 1.15.10 milestone Apr 23, 2025
@s1na s1na changed the title ethclient: add AuthList field in toCallArg ethclient: allow passing AuthorizationList to calls Apr 23, 2025
@s1na s1na merged commit 846c14e into ethereum:master Apr 23, 2025
4 checks passed
sduchesneau pushed a commit to streamingfast/go-ethereum that referenced this pull request May 22, 2025
…thereum#3048)

This PR adds the `AuthorizationList` field to the `CallMsg` interface to support `eth_call`
and `eth_estimateGas` of set-code transactions.

---------

Co-authored-by: colin <102356659+colinlyguo@users.noreply.github.com>
Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
@colinlyguo colinlyguo deleted the client-add-AuthList-field-in-toCallArg branch June 7, 2025 10:32
jakub-freebit pushed a commit to fblch/go-ethereum that referenced this pull request Jul 3, 2025
This PR adds the `AuthorizationList` field to the `CallMsg` interface to support `eth_call`
and `eth_estimateGas` of set-code transactions.

---------

Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
howjmay pushed a commit to iotaledger/go-ethereum that referenced this pull request Aug 27, 2025
This PR adds the `AuthorizationList` field to the `CallMsg` interface to support `eth_call`
and `eth_estimateGas` of set-code transactions.

---------

Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
gballet pushed a commit to gballet/go-ethereum that referenced this pull request Sep 11, 2025
This PR adds the `AuthorizationList` field to the `CallMsg` interface to support `eth_call`
and `eth_estimateGas` of set-code transactions.

---------

Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants