-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
feat(anvil
): Core types migration
#6808
Conversation
* feat: remove most ethers and old anvil core types * chore: replace handles for providers constructed on actual tests * finish moving test providers * chore: switch to decode_revert * chore: replace with maybe_decode_revert * u256::decode * chore: move all of anvil but tests and block subscriptions off ethers * re-enable opt * solve nits * chore: remove more println * chore: rename to gen
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.
just minor nits to add
deny check comes from mdbook's |
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 when we figure out why the signed data is diff
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.
what regressions do we expect?
there a few reported rlp/signing issues on alloy
looks like everything's passing here though
@mattsse I expect no regressions for this PR as the test suite is saying everything's okay, but the rlp/signing issues on alloy make me feel a bit uneasy. I think we should put our attention there and fix upstream before we merge this, just to be careful. |
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.
last nits
Blocked on alloy-rs/core#499, needs an alloy-rs/alloy followup afterwards with the functionality in the aforementioned PR so we can get the same hashes on typed data as before. |
41e9b60
to
07fb76d
Compare
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.
gg
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.
Send and onto the next!
Motivation
Migrates Anvil to use alloy. This brings over types from Alloy Primitives, along with custom types which Anvil needs, mainly to support Optimism deposit transactions, and its internal execution logic.
The big diff is mainly concerned with the deletion of a lot of unneeded files.
Only test utilities which are needed on anvil remain on ethers (Related to providers). Followup PRs will remove ethers from anvil tests completely and subsequently remove the ethers dep.
Solution
Move Anvil to use Alloy. A couple of things to note:
{ v: 0, r: 0, s: 0}
anymore, as it's not possible to construct such signature with our new Signature type. It's changed to{ v: 1, r: 1, s: 1}
.