-
Notifications
You must be signed in to change notification settings - Fork 170
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
feat: automatically clear unsupplied blacklisted tokens #1808
Conversation
Codecov Report
📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more @@ Coverage Diff @@
## main #1808 +/- ##
==========================================
- Coverage 57.80% 57.72% -0.09%
==========================================
Files 78 78
Lines 8023 8044 +21
==========================================
+ Hits 4638 4643 +5
- Misses 3047 3061 +14
- Partials 338 340 +2
|
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.
Could you clarify when and why we want to remove tokens from the registry? Before you said that we don't want to do that. Let's discuss in the thread in the 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.
Might want to make this a bit more clear on the proposal side.
Let's add something like an "AttemptDelete" flag
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.
Pre-approving. Added one small request in the thread
* feat: automatically clear unsupplied blacklisted tokens * cl++ * add oracle hooks call * lint++ * README++ --------- Co-authored-by: Robert Zaremba <robert@zaremba.ch> (cherry picked from commit 614d2c5)
* feat: automatically clear unsupplied blacklisted tokens * cl++ * add oracle hooks call * lint++ * README++ --------- Co-authored-by: Robert Zaremba <robert@zaremba.ch> (cherry picked from commit 614d2c5) Co-authored-by: Adam Moser <63419657+toteki@users.noreply.github.com>
When a leverage registry update passes (regardless of whether it blacklisted any tokens), the module checks for any existing blacklisted tokens with zero supply and deletes them.
If supply is nonzero, deletion is not acceptable because the module would lose the ability to interpret existing uToken balances, reserves, borrows, etc for the blacklisted base denom.