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

fix governance proposal execution #3087

Merged
merged 5 commits into from
Apr 27, 2024

Conversation

Fraccaman
Copy link
Member

@Fraccaman Fraccaman commented Apr 16, 2024

Describe your changes

Indicate on which release or other PRs this topic is based on

Checklist before merging to draft

  • I have added a changelog
  • Git history is in acceptable state

@Fraccaman Fraccaman requested a review from grarco April 16, 2024 13:13
Copy link

codecov bot commented Apr 16, 2024

Codecov Report

Attention: Patch coverage is 17.77778% with 37 lines in your changes are missing coverage. Please review.

Project coverage is 59.42%. Comparing base (97ec5b4) to head (4339d43).
Report is 4 commits behind head on main.

Files Patch % Lines
...rates/apps/src/lib/node/ledger/shell/governance.rs 0.00% 35 Missing ⚠️
crates/governance/src/storage/proposal.rs 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3087      +/-   ##
==========================================
+ Coverage   59.39%   59.42%   +0.02%     
==========================================
  Files         298      298              
  Lines       92771    92762       -9     
==========================================
+ Hits        55104    55122      +18     
+ Misses      37667    37640      -27     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Comment on lines +84 to +98
// Is VP triggered by a governance proposal?
let is_governance_proposal = is_proposal_accepted(
&self.ctx.pre(),
tx_data.data().unwrap_or_default().as_ref(),
)
.unwrap_or_default();

let native_token = self.ctx.pre().get_native_token()?;

// Find the actions applied in the tx
let actions = self.ctx.read_actions()?;

// There must be at least one action if any of the keys belong to gov
if actions.is_empty()
if !is_governance_proposal
&& actions.is_empty()
Copy link
Member Author

Choose a reason for hiding this comment

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

@tzemanovic I had to add this condition

grarco
grarco previously approved these changes Apr 17, 2024
Copy link
Collaborator

@grarco grarco 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! The proposal_ibc_token_inflation will keep failing until we fix #3068 so we can ignore it for the time being

brentstone added a commit that referenced this pull request Apr 18, 2024
* fraccaman/fix-governance-proposal-execution:
  changelog: add #3087
  end voting once the voting end epoch begins
  remove print
  fix governance proposal execution
  fix governance proposal execution
brentstone added a commit that referenced this pull request Apr 18, 2024
* fraccaman/fix-governance-proposal-execution:
  changelog: add #3087
  end voting once the voting end epoch begins
  remove print
  fix governance proposal execution
  fix governance proposal execution
@brentstone brentstone merged commit 5dd4042 into main Apr 27, 2024
17 of 19 checks passed
@brentstone brentstone deleted the fraccaman/fix-governance-proposal-execution branch April 27, 2024 00:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants