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

Add proto compatible x/distribution tx cli #5941

Merged
merged 8 commits into from
Apr 8, 2020

Conversation

sahith-narahari
Copy link
Contributor

@sahith-narahari sahith-narahari commented Apr 6, 2020

Reference: #5864

Description


For contributor use:

  • Targeted PR against correct branch (see CONTRIBUTING.md)
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the module structure standards.
  • Wrote unit and integration tests
  • Updated relevant documentation (docs/) or specification (x/<module>/spec/)
  • Added relevant godoc comments.
  • Added a relevant changelog entry to the Unreleased section in CHANGELOG.md
  • Re-reviewed Files changed in the Github PR explorer

For admin use:

  • Added appropriate labels to PR (ex. WIP, R4R, docs, etc)
  • Reviewers assigned
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)

Copy link
Collaborator

@anilcse anilcse left a comment

Choose a reason for hiding this comment

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

lgtm.

Added a few commetns on style fixes. Please check

x/distribution/client/cli/tx.go Show resolved Hide resolved
x/distribution/client/cli/tx.go Outdated Show resolved Hide resolved
x/distribution/client/cli/tx.go Show resolved Hide resolved
x/distribution/client/cli/tx.go Show resolved Hide resolved
x/distribution/client/cli/tx.go Show resolved Hide resolved
x/distribution/client/cli/tx.go Show resolved Hide resolved
x/distribution/client/rest/tx.go Outdated Show resolved Hide resolved
x/distribution/client/rest/tx.go Outdated Show resolved Hide resolved
@alexanderbez alexanderbez added C:CLI R4R C:x/distribution distribution module related labels Apr 7, 2020
x/distribution/client/rest/rest.go Outdated Show resolved Hide resolved
x/distribution/client/cli/tx.go Show resolved Hide resolved
x/distribution/client/cli/tx.go Outdated Show resolved Hide resolved
x/distribution/client/cli/tx.go Show resolved Hide resolved
@alexanderbez
Copy link
Contributor

Looks great @sahith-narahari, thanks! Just a few minor bits of feedback.

@fedekunze fedekunze changed the title Add proto compatible x/ditribution tx cli Add proto compatible x/distribution tx cli Apr 8, 2020
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.

utACK

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.

Amazing. Thanks @sahith-narahari!

@fedekunze fedekunze added the A:automerge Automatically merge PR once all prerequisites pass. label Apr 8, 2020
@fedekunze
Copy link
Collaborator

@sahith-narahari mind updating the branch one last time? 🙏 It's out-of-date

@sahith-narahari
Copy link
Contributor Author

@fedekunze updated

@alexanderbez alexanderbez merged commit ed9f488 into cosmos:master Apr 8, 2020
@sahith-narahari sahith-narahari deleted the sahith/distr-tx-proto branch April 8, 2020 17:40
txf := tx.NewFactoryFromCLI(inBuf).
WithTxGenerator(txg).
WithAccountRetriever(ar)
cliCtx := context.NewCLIContextWithInputAndFrom(inBuf, args[0]).WithMarshaler(m)
Copy link
Member

Choose a reason for hiding this comment

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

Should be NewCLIContextWithInput as args[0] actually doesn't point to anything - this will probably cause an out of bounds panic.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the review @aaronc, I see there's same issue in multiple modules. I addressed them all in a seperate PR

@sahith-narahari sahith-narahari mentioned this pull request Apr 9, 2020
11 tasks
@clevinson clevinson added this to the v0.39 milestone May 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A:automerge Automatically merge PR once all prerequisites pass. C:CLI C:x/distribution distribution module related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants