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

x/gov: Queries to /gov/proposals/{proposalID}/votes support pagination #5405

Merged
merged 5 commits into from
Dec 18, 2019

Commits on Dec 17, 2019

  1. x/gov: Queries to /gob/proposals/{proposalID}/votes support pagination

    Changes:
    - votes for active proposals are paginated by applying page limits to results stored in keeper
    - for inactive proposals we paginate what we receive from tendermint.TxSearch
    tendermint.TxSearch paginates transactions, not messages. I noticed that current gov application allows to
    submit only one msg per tx. But tx structure suggests that there could be many messages in a single transaction.
    Hence we load transactions in batches (30), unpacking them and once we collected enough votes - query is terminted.
    Or it will be terminted if we run out off transactions.
    
    Other changes:
    - add separate type for proposal votes queries
    - extended cli to query gov vote with '--page' and '--limit' flags
    
    Signed-off-by: dmitry <[email protected]>
    dshulyak committed Dec 17, 2019
    Configuration menu
    Copy the full SHA
    aa56aa9 View commit details
    Browse the repository at this point in the history

Commits on Dec 18, 2019

  1. Configuration menu
    Copy the full SHA
    0af476a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8a6ded8 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1caad87 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    fd6208b View commit details
    Browse the repository at this point in the history