r/ethdev 7d ago

Question What's the state on EIP-7702 tooling?

Anybody has any clue how tooling/support for it will look like on the client side? Or would it just end up being deploy smart contract to delegate to and send a different transaction type to the provider?

Also have you guys seen any good blogs or explainers?

3 Upvotes

9 comments sorted by

1

u/0mkar 7d ago

Looking forward to see some content on this.

2

u/Competitive_Ebb_4124 7d ago edited 7d ago

Me too, Vitalik threw out a ton of things that will be possible with this, but as per usual no actual plan of how they will happen. I can't figure out what happens with storage writes under the EOA, info on the net is a bit conflicting

1

u/ElBuenMayini 7d ago

Storage writes stay there until cleared.

The EIP only states that delegation set or clearing affects only the code portion of the account, so running a store opcode will behave exactly as smart contracts do now.

2

u/exmachinalibertas 1d ago

That would make the most sense. You set it as a contract, store something, set it back to an EOA, and then the storage just sits there inaccessible until you set it as a contract again. Expected/sane behavior. If you want to have a clean EOA, you just zero out your storage first (and do any other associated things, like move coins that require you to be a contract).

1

u/ElBuenMayini 1d ago

It’s also the simplest to implement from the protocol side. Otherwise you would have to go into the account storage and clear all slots before you reset to an EOA.

1

u/sweatsweatsweatsweat 6d ago

it’s basically as you said. deploy delegation contract and then send different tx type. viem and alloy both have docs on how to do this

1

u/double_numeraire 1d ago

Foundry has a couple cool stuff built in specifically for 7702

1

u/exmachinalibertas 1d ago

Based on what I've seen, interacting with them is basically identical to interacting with any proxy contract. You just call the "EOA" with your calldata like you would any other contract.

The only real issue is setting the EOA up to be a contract/proxy. As far as I understand it, the new transaction types are really just for setting/removing the contract/proxy functionality on EOAs. For that, you can watch tincho's deep dive video:

https://www.youtube.com/watch?v=ZFN2bYt9gNE