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

Converted balance from sdk.Int to sdk.Coin inside DelegationResponse #4806

Merged
merged 6 commits into from
Aug 2, 2019
Merged

Converted balance from sdk.Int to sdk.Coin inside DelegationResponse #4806

merged 6 commits into from
Aug 2, 2019

Conversation

RiccardoM
Copy link
Contributor

@RiccardoM RiccardoM commented Jul 30, 2019

Description

Updated the type of balance inside DelegationResponse to be sdk.Coin instead of sdk.Int to work towards response standardization as described inside #4783.

Check list

  • Linked to github-issue with discussion and accepted design OR link to spec that describes this work.
  • Wrote tests
  • Updated relevant documentation (docs/)
  • Added a relevant changelog entry: clog add [section] [-t <tag>] [-m <msg>]
  • Re-reviewed Files changed in the github PR explorer

For Admin Use:

  • Added appropriate labels to PR (ex. wip, ready-for-review, docs)
  • Reviewers Assigned
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)

@fedekunze
Copy link
Collaborator

fedekunze commented Jul 30, 2019

@RiccardoM mind pulling from master? There was a recent issue with CI that's now resolved

@RiccardoM
Copy link
Contributor Author

@fedekunze Done ✔️

@RiccardoM
Copy link
Contributor Author

Can someone help me with the clog command? I don't know what to write 🤔

@alexanderbez
Copy link
Contributor

alexanderbez commented Jul 31, 2019

@RiccardoM

$ clog add breaking -t rest -m "The balance field in the DelegationResponse type is now sdk.Coin instead of sdk.Int"

Thanks!

Copy link
Collaborator

@fedekunze fedekunze left a comment

Choose a reason for hiding this comment

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

sorry @RiccardoM . We need to also update the swagger.yaml output for the delegation responses

@RiccardoM
Copy link
Contributor Author

@RiccardoM

$ clog add breaking -t rest -m "The balance field in the DelegationResponse type is now sdk.Coin instead of sdk.Int"

Thanks!

I can't seem able to perform this command. Which executable should I have installed? I tried using clog-cli from Github but it didn't work

@codecov
Copy link

codecov bot commented Aug 1, 2019

Codecov Report

Merging #4806 into master will decrease coverage by 0.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #4806      +/-   ##
==========================================
- Coverage    50.5%   50.49%   -0.02%     
==========================================
  Files         288      288              
  Lines       18516    18516              
==========================================
- Hits         9351     9349       -2     
- Misses       8480     8482       +2     
  Partials      685      685

@codecov
Copy link

codecov bot commented Aug 1, 2019

Codecov Report

Merging #4806 into master will decrease coverage by 0.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #4806      +/-   ##
==========================================
- Coverage   54.21%   54.19%   -0.02%     
==========================================
  Files         269      269              
  Lines       17179    17179              
==========================================
- Hits         9313     9311       -2     
- Misses       7176     7178       +2     
  Partials      690      690

@alexanderbez
Copy link
Contributor

@RiccardoM make tools.

@RiccardoM
Copy link
Contributor Author

@alexanderbez Thank you! Done!

@RiccardoM
Copy link
Contributor Author

sorry @RiccardoM . We need to also update the swagger.yaml output for the delegation responses

Done!

@@ -2365,8 +2365,8 @@ definitions:
type: string
shares:
type: string
height:
Copy link
Collaborator

Choose a reason for hiding this comment

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

why was this deleted ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Looking at the LCD response, it didn't appear to be present inside the response itself. Am I wrong or was it an error?

Copy link
Contributor

Choose a reason for hiding this comment

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

The entire swagger config needs to be refactored (responses are now: {"height": X, "result": Y})

Copy link
Contributor Author

Choose a reason for hiding this comment

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

So, can we resolve this and open up another issue?

Copy link
Collaborator

Choose a reason for hiding this comment

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

👍 mind opening it?

Copy link
Contributor

@alessio alessio left a comment

Choose a reason for hiding this comment

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

Looks good to me - @fedekunze's comment (https://github.com/cosmos/cosmos-sdk/pull/4806/files#r309864932) should be addressed before merging

@fedekunze fedekunze added the T: API Breaking Breaking changes that impact APIs and the SDK only (not state machine). label Aug 2, 2019
Co-Authored-By: Alexander Bezobchuk <alexanderbez@users.noreply.github.com>
Copy link
Contributor

@alexanderbez alexanderbez left a comment

Choose a reason for hiding this comment

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

ACK

@alexanderbez alexanderbez merged commit f218de8 into cosmos:master Aug 2, 2019
@RiccardoM RiccardoM mentioned this pull request Aug 3, 2019
4 tasks
@RiccardoM RiccardoM deleted the riccardom/coin-int-replacement branch October 16, 2019 11:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T: API Breaking Breaking changes that impact APIs and the SDK only (not state machine).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants