Skip to content

fix: Enforce voting threshold param in oracle endblocker#1707

Merged
rbajollari merged 11 commits intomainfrom
ryan/vote-threshold
Feb 7, 2023
Merged

fix: Enforce voting threshold param in oracle endblocker#1707
rbajollari merged 11 commits intomainfrom
ryan/vote-threshold

Conversation

@rbajollari
Copy link
Copy Markdown
Collaborator

Description

When updating the oracle rewarding in Ojo we noticed that the param VoteThreshold was not being used to enforce a minimum percentage of votes for a ballot to pass. This PR adds that enforcement and a unit test for it.


Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • included the correct type prefix in the PR title
  • added ! to the type prefix if API or client breaking change
  • added appropriate labels to the PR
  • targeted the correct branch (see PR Targeting)
  • provided a link to the relevant issue or specification
  • added a changelog entry to CHANGELOG.md
  • included comments for documenting Go code
  • updated the relevant documentation or specification
  • reviewed "Files changed" and left comments if necessary
  • confirmed all CI checks have passed

Reviewers Checklist

All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.

I have...

  • confirmed the correct type prefix in the PR title
  • confirmed all author checklist items have been addressed
  • reviewed state machine logic
  • reviewed API design and naming
  • reviewed documentation is accurate
  • reviewed tests and test coverage
  • manually tested (if applicable)

@rbajollari rbajollari marked this pull request as ready for review January 11, 2023 16:35
@rbajollari rbajollari requested a review from a team as a code owner January 11, 2023 16:35
Copy link
Copy Markdown
Contributor

@robert-zaremba robert-zaremba left a comment

Choose a reason for hiding this comment

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

So we are ignoring an update and will have updated price? We need some notification about that.

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Jan 24, 2023

Codecov Report

Merging #1707 (18d17e3) into main (88969af) will increase coverage by 0.02%.
The diff coverage is 100.00%.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1707      +/-   ##
==========================================
+ Coverage   57.83%   57.85%   +0.02%     
==========================================
  Files          78       78              
  Lines        8013     8017       +4     
==========================================
+ Hits         4634     4638       +4     
  Misses       3043     3043              
  Partials      336      336              
Impacted Files Coverage Δ
x/oracle/abci.go 81.81% <100.00%> (+0.76%) ⬆️

Copy link
Copy Markdown
Collaborator

@adamewozniak adamewozniak left a comment

Choose a reason for hiding this comment

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

pre-approving with a couple comments 👍

@rbajollari rbajollari merged commit 852ff39 into main Feb 7, 2023
@rbajollari rbajollari deleted the ryan/vote-threshold branch February 7, 2023 18:59
@rbajollari rbajollari mentioned this pull request Feb 9, 2023
17 tasks
@toteki
Copy link
Copy Markdown
Contributor

toteki commented Feb 14, 2023

@Mergifyio backport release.v4.1.x

@mergify
Copy link
Copy Markdown
Contributor

mergify bot commented Feb 14, 2023

backport release.v4.1.x

❌ No backport have been created

Details
  • Backport to branch release.v4.1.x failed: Branch not found

@mergify
Copy link
Copy Markdown
Contributor

mergify bot commented Feb 14, 2023

backport release/v4.1.x

✅ Backports have been created

Details

mergify bot pushed a commit that referenced this pull request Feb 14, 2023
* Enforce vote threshold in oracle endblocker

* Add logging

* Fix conflict issues

* pr comments

---------

Co-authored-by: Adam Wozniak <29418299+adamewozniak@users.noreply.github.com>
(cherry picked from commit 852ff39)

# Conflicts:
#	x/oracle/abci.go
toteki added a commit that referenced this pull request Feb 14, 2023
) (#1816)

* fix: Enforce voting threshold param in oracle endblocker (#1707)

* Enforce vote threshold in oracle endblocker

* Add logging

* Fix conflict issues

* pr comments

---------

Co-authored-by: Adam Wozniak <29418299+adamewozniak@users.noreply.github.com>
(cherry picked from commit 852ff39)

# Conflicts:
#	x/oracle/abci.go

* remove conflict

* lint++

* func--

* Revert

* fix merge

* lint++

---------

Co-authored-by: ryanbajollari <54822716+rbajollari@users.noreply.github.com>
Co-authored-by: Adam Moser <63419657+toteki@users.noreply.github.com>
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.

5 participants