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

Bing/ft swap monitor #349

Merged
merged 1 commit into from
Aug 7, 2024
Merged

Bing/ft swap monitor #349

merged 1 commit into from
Aug 7, 2024

Conversation

bingyuyap
Copy link
Contributor

@bingyuyap bingyuyap commented Aug 6, 2024

This PR adds swap layer parsing for Redeem transactions which allows us to:

  1. identify the end of a fast transfer
  2. identify the output amount, output token and relaying fee

The ID of a redeem_swap is fill_vaa_id which is generated in the execute_fast_transfer_* stages. Another PR will be opened to add the fill_vaa_id in the these stages.

Note: that the swap layer is not deployed on devnet (as we need mainnet quotes from dexes we will test on mainnet) hence the need for mocked data in the test and lack thereof test for getting swap transactions within range. These will be added once the mainnet deployment is done.

@bingyuyap bingyuyap force-pushed the bing/ft-swap-monitor branch 13 times, most recently from e1dd63a to b2aafbf Compare August 7, 2024 03:59
@bingyuyap bingyuyap marked this pull request as ready for review August 7, 2024 04:05
@bingyuyap bingyuyap marked this pull request as draft August 7, 2024 12:13
@bingyuyap bingyuyap marked this pull request as ready for review August 7, 2024 12:25
@bingyuyap bingyuyap force-pushed the bing/ft-swap-monitor branch 4 times, most recently from dd540de to 1a5b2fb Compare August 7, 2024 15:35
@bingyuyap bingyuyap force-pushed the bing/ft-swap-monitor branch 3 times, most recently from b61f268 to b449da1 Compare August 7, 2024 15:46
test: initial swap monitor testing

ft_swap: parse redeem params to get fill vaa

add id for redeem event

ft_watcher: parse swap event and input

ft_watcher: plug swap layer into ft watcher

Signed-off-by: bingyuyap <[email protected]>
@bingyuyap bingyuyap merged commit 63aaa73 into main Aug 7, 2024
3 checks passed
@bingyuyap bingyuyap deleted the bing/ft-swap-monitor branch August 7, 2024 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants