Skip to content

feat: migrate univ2 to SwapQuoter#523

Open
kayibal wants to merge 5 commits intomainfrom
ah/migrate-univ2-swap-quoter
Open

feat: migrate univ2 to SwapQuoter#523
kayibal wants to merge 5 commits intomainfrom
ah/migrate-univ2-swap-quoter

Conversation

@kayibal
Copy link
Copy Markdown
Collaborator

@kayibal kayibal commented Feb 2, 2026

A preview on how to migrate a protocol to the new trait.

Copy link
Copy Markdown
Collaborator

@dianacarvalho1 dianacarvalho1 left a comment

Choose a reason for hiding this comment

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

Thank you @kayibal ! Only have one suggestion

tokens: &HashMap<Bytes, Token>,
_decoder_context: &DecoderContext,
) -> Result<Self, Self::Error> {
let component = ProtocolComponent::<Arc<Token>>::new(
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

couldn't we pass the ProtocolComponent already from the decoder? I think we already know them at this time

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

We probably can, but I didn't want to break more interfaces right now.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

but this would be the time to break all the interfaces no? 👀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

2 participants