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

VAULT: Mint To should fail if depositor gets 0 VRT for any amount of ST #147

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

coachchucksol
Copy link
Contributor

There are scenarios, like front running an initial deposit, where a depositor can received 0 VRT given some ST deposit. This should never be the case. This is in addition to min_amount_out.

Copy link

codecov bot commented Oct 24, 2024

Codecov Report

Attention: Patch coverage is 60.00000% with 2 lines in your changes missing coverage. Please review.

Project coverage is 77.58%. Comparing base (249a57c) to head (5b3556f).

Files with missing lines Patch % Lines
vault_program/src/mint_to.rs 60.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #147      +/-   ##
==========================================
- Coverage   77.59%   77.58%   -0.01%     
==========================================
  Files          87       87              
  Lines        8903     8911       +8     
==========================================
+ Hits         6908     6914       +6     
- Misses       1995     1997       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@ebatsell ebatsell left a comment

Choose a reason for hiding this comment

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

This change is pretty harmless, would like to understand if this solves all cases of the frontrunning issue or there's more to be done

@coachchucksol coachchucksol marked this pull request as draft October 25, 2024 02:28
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