web3swift
web3swift copied to clipboard
ERC-4337: milestone planning
What context is your feature request related to?
This issue is focused on preparing a milestone, a clear vision and a path for implementing the ERC-4337 support.
What solution would you like?
Most parts of ERC-4337 are not related to web3swift in terms that web3swift does not provide node software. The plan and the complete backlog of tasks to be completed to mark ERC-4337 as supported shouldn't be large.
Image borrowed from medium post.
Out of these 4 stages shown in the image we only touch on the first: Users and Applications. At least that's my understanding at the moment. We will see what else we need as we go.
Any additional context?
No response
Ah, okay, I see more intersections with the library.
I'll quickly draft an incomplete list of things we need:
- new model UserOperation;
- API to send
UserOperation
to mempool. I expect a way similar toeth_sendTransaction
/eth_sendRawTransaction
but now forUserOperation
; - default implementation of EntryContract with the ability to call it directly. In case user wants to a bundle of 1 or more
UserOperation
objects; - Bundler implementation - a way to bundle operations locally (do we need it/can we implement it? Not sure about the "For each aggregator, run the aggregator-specific code to create aggregated signature, and update the UserOps" in the Bundler's algorithm).
The more I read the standard the more tasks I see. I'll have to devote a healthy chunk of time to make something useful that we can eventually call a plan.
All thoughts are welcome.