-
Notifications
You must be signed in to change notification settings - Fork 154
Migrate OrderCreation and signature handling to alloy types #3936
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
Conversation
crates/e2e/tests/e2e/liquidity.rs
Outdated
| maker_amount: order_creation.buy_amount.try_into().unwrap(), | ||
| taker_amount: order_creation.sell_amount.try_into().unwrap(), |
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.
Where did multiplication go?
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.
Oooof great catch, this was probably migrated by Claude
m-sz
left a comment
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 except for the missed multiplication as pointed out by @squadgazzz, will be happy to approve once it's fixed.
Description
This PR continues the migration from ethcontract types to alloy primitives, focusing on order
creation, signature handling, and test infrastructure. This is part of the broader effort to
adopt alloy as the primary Ethereum library across the codebase.
The changes primarily affect the e2e test suite and related infrastructure, migrating from
ethcontract::H160andethcontract::U256toalloy::primitives::Addressandalloy::primitives::U256respectively.Changes
OrderCreationfields to use alloyAddressandU256types.into_legacy()conversions whereneeded
to_wei()witheth()helper throughout e2e testscolocation.rs,solution.rs) to use alloyAddressservices.rsto accept alloy addresses.into_alloy()conversions where values are already alloy typesHow to test
Existing tests