Skip to content

fix(gov): parse expedited proposal responses - #449

Open
ChrisWozniak wants to merge 1 commit into
fetchai:mainfrom
ChrisWozniak:fix/gov-expedited-proposals
Open

fix(gov): parse expedited proposal responses#449
ChrisWozniak wants to merge 1 commit into
fetchai:mainfrom
ChrisWozniak:fix/gov-expedited-proposals

Conversation

@ChrisWozniak

Copy link
Copy Markdown

Proposed Changes

  • Allow Governance proposal REST responses to contain fields newer than the generated Proposal protobuf model.
  • Add regression tests for single-proposal and proposal-list responses containing is_expedited.

Linked Issues

Fixes #364

Types of changes

  • Bug fix (non-breaking change that fixes an issue).
  • New feature added (non-breaking change that adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to stop working as expected).
  • Documentation update.
  • Something else (e.g., tests, scripts, example, deployment, infrastructure).

Checklist

  • I have read the CONTRIBUTING guide.
  • Checks and tests pass locally.

If applicable

  • I have added tests that prove my fix is effective or that my feature works.
  • I have checked that code coverage does not decrease.
  • I have added/updated the documentation.

Further comments

The generated cosmos.gov.v1beta1 Proposal model predates is_expedited. Ignoring unknown response fields restores compatibility without a broad protobuf regeneration; all currently modelled proposal fields continue to parse.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug report: GovClient.Proposal cannot consume expedited proposals

2 participants