feat: take into account hideAbstain
when computing results
#1091
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Closes: https://github.com/snapshot-labs/workflow/issues/380
This PR uses the
hideAbstain
property in the space settings, when computing results.When
hideAbstain
is enabled,abstain
in basic voting is ignored from the quorum and resultsHow to test
hideAbstain
enabled: http://localhost:8080/#/s:safe.eth/proposal/0x5cf64434792565591b005460db0460e9314753178d4aa5475dfc0ce4d45638a2abstain
choice from the results list, and quorum should not take abstain scores into account. Results should be same as v1 https://v1.snapshot.box/#/safe.eth/proposal/0x5cf64434792565591b005460db0460e9314753178d4aa5475dfc0ce4d45638a2Notes
Excluding ABSTAIN from all scores results in lower quorum, and is marking a proposal that have passed before this PR as rejected (see the example proposal above)
Since the
hide_abstain
option can change proposal outcome depending on its setting, it should not be a global option, and each proposal should have its own local copy (likeprivacy
)