-
Notifications
You must be signed in to change notification settings - Fork 169
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!: MaxBorrow query and modify MaxWithdraw to return all denoms #1683
Conversation
Codecov Report
@@ Coverage Diff @@
## main #1683 +/- ##
==========================================
+ Coverage 57.82% 57.97% +0.15%
==========================================
Files 73 73
Lines 7589 7821 +232
==========================================
+ Hits 4388 4534 +146
- Misses 2858 2934 +76
- Partials 343 353 +10
|
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.
- Let's simplify and merge
All*
queries by making the denom optional and always returning a list. - let's write at least one simple test for the Query RPC.
Merged queries and added basic tests. Note that PR is now proto-breaking (only for the |
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.
preapproving. As noted in the comment, let's remove the optional
flag. According to the proto documentation it doesn't change anything, but makes the implementation a bit more obscure.
Description
In addition to the existing historacle-enabled
MaxWithdraw
query, this PR implements the following:MaxBorrow
In addition, the
Denom
field in those queries is now optional, and they returnsdk.Coins
instead ofsdk.Coin
. If denom is not specified, calculates max borrow/withdraw for ALL registered tokens.See proto file for query urls and data types.
Author Checklist
All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.
I have...
!
to the type prefix if API or client breaking changeCHANGELOG.md
Reviewers Checklist
All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.
I have...