Skip to content
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

Ignore ETH wrapping transfers #322

Merged
merged 2 commits into from
Oct 5, 2023
Merged

Ignore ETH wrapping transfers #322

merged 2 commits into from
Oct 5, 2023

Conversation

fhenneke
Copy link
Collaborator

@fhenneke fhenneke commented Oct 5, 2023

Before only transfers from WETH to the contract were ignored. those
correspond to unwraps/withdrawals.
With this change, also transfers from the protocol to WETH are ignored.
those correspond to wraps/deposits.

The general idea is that all transfers between the protocol and WETH should
correspond to wrapping and unwrapping. Such operations do change the ETH balance
and WETH balance without incurring any slippage or change in value of the buffers.

Before only transfers from WETH to the contract were ignored. those
correspond to unwraps/withdrawals.
With this change, also transfers from the protocol to WETH are ignored.
those correspond to wraps/deposits.

The general idea is that all transfers between the protocol and WETH should
correspond to wrapping and unwrapping. Such operations do change the ETH balance
and WETH balance without incurring any slippage or change in value of the buffers.
@fhenneke fhenneke requested a review from harisang October 5, 2023 08:33
Copy link
Contributor

@bh2smith bh2smith left a comment

Choose a reason for hiding this comment

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

Seems reasonable!

@fhenneke fhenneke merged commit 005c75d into main Oct 5, 2023
5 checks passed
@fhenneke fhenneke deleted the ignore_eth_wrap branch October 5, 2023 11:43
@github-actions github-actions bot locked and limited conversation to collaborators Oct 5, 2023
@fhenneke
Copy link
Collaborator Author

PR #323 fixes a problem with this PR.
The problem was that even though the query period_slippage.sql itself is correctly adapted, the code still called a Dune query without the changes.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants