Skip to content

feat(nns): Make distinction between potential and deciding voting power. - #2339

Merged
aterga merged 4 commits into
masterfrom
deciding_voting_power-daniel-wong
Nov 5, 2024
Merged

aterga merged 4 commits into
masterfrom
deciding_voting_power-daniel-wong

Conversation

@daniel-wong-dfinity-org

@daniel-wong-dfinity-org daniel-wong-dfinity-org commented Oct 30, 2024 •

Copy link
Copy Markdown
Contributor

Add deciding_voting_power method to Neuron.

Renames the voting_power method of Neuron to potential_voting_power.

Added a flag that controls whether deciding_voting_power applies adjustment. Per usual, adjustment is off in vanilla builds, but on when feature = "test".

Voting rewards uses this new method. As long as the the new behavior is not enabled (via the flag), this should result in no behavior change, and even initially, when the feature is enabled, since no neuron can be too unrefreshed, even then, there would be no immediate behavior change.

Background

This is part of the "periodic confirmation" feature that was recently approved in proposal 132411.

References

Closes https://dfinity.atlassian.net/browse/NNS1-3406, https://dfinity.atlassian.net/browse/NNS1-3407.

👈 Previous PR | Next PR 👉

@daniel-wong-dfinity-org
daniel-wong-dfinity-org changed the base branch from master to linear-map-daniel-wong October 30, 2024 16:18
@github-actions github-actions Bot added the feat label Oct 30, 2024
@daniel-wong-dfinity-org
daniel-wong-dfinity-org force-pushed the deciding_voting_power-daniel-wong branch from ccdfb66 to ca2a563 Compare October 30, 2024 18:08
@daniel-wong-dfinity-org
daniel-wong-dfinity-org marked this pull request as ready for review October 30, 2024 21:04
@daniel-wong-dfinity-org
daniel-wong-dfinity-org requested a review from a team as a code owner October 30, 2024 21:04
@daniel-wong-dfinity-org
daniel-wong-dfinity-org force-pushed the deciding_voting_power-daniel-wong branch 4 times, most recently from 0dffb46 to 4b326ea Compare October 31, 2024 17:19
@daniel-wong-dfinity-org
daniel-wong-dfinity-org force-pushed the deciding_voting_power-daniel-wong branch from 4b326ea to 3f02b4b Compare October 31, 2024 17:30
@daniel-wong-dfinity-org
daniel-wong-dfinity-org force-pushed the deciding_voting_power-daniel-wong branch from 97d1973 to 2529333 Compare October 31, 2024 21:13
github-merge-queue Bot pushed a commit that referenced this pull request Oct 31, 2024
This was spun out of sns governance so that it can be used elsewhere (in
another PR that I'm working on).

# References

(No ticket.)

[👈 Previous PR][prev] | [Next PR 👉][next]

[prev]: #2320
[next]: #2339
Base automatically changed from linear-map-daniel-wong to master October 31, 2024 21:50
@daniel-wong-dfinity-org
daniel-wong-dfinity-org force-pushed the deciding_voting_power-daniel-wong branch from 2529333 to a7686cd Compare October 31, 2024 22:41
Comment thread rs/nns/governance/src/neuron/types.rs Resolved
Comment thread rs/nns/governance/src/neuron/types.rs Resolved
Comment thread rs/nns/governance/src/neuron/types.rs Resolved
@aterga
aterga enabled auto-merge November 5, 2024 21:17
@aterga
aterga added this pull request to the merge queue Nov 5, 2024
Merged via the queue into master with commit 7927c34 Nov 5, 2024
@aterga
aterga deleted the deciding_voting_power-daniel-wong branch November 5, 2024 21:31
github-merge-queue Bot pushed a commit that referenced this pull request Nov 7, 2024
# Background

This is part of the "periodic confirmation" feature that was recently
approved in proposal [132411][prop].

[prop]: https://dashboard.internetcomputer.org/proposal/132411

# Future Work

This will be used in the calculation of voting rewards. Whereas, before,
the total voting power in ballots (i.e. "deciding" voting power) was
used as the baseline to determine each neuron's share of the reward
purse. With the distinction between potential voting power vs. deciding
voting power (implemented in an earlier PR in this series), if we
continued to do it the old way, the pie would be sliced into a smaller
number of pieces. When this new field is used, the pie will continue to
be sliced into the same number of pieces today. This way, neurons that
stay refreshed will keep getting the same amount of rewards (not more),
while those who do not stay refreshed will get less.

# References

Closes https://dfinity.atlassian.net/browse/NNS1-3411.

[👈 Previous PR][prev] | [Next PR 👉][next]

[prev]: #2339
[next]: #2385
alin-at-dfinity pushed a commit that referenced this pull request Nov 7, 2024
…er. (#2339)

Add deciding_voting_power method to Neuron.

Renames the voting_power method of Neuron to potential_voting_power.

Added a flag that controls whether deciding_voting_power applies
adjustment. Per usual, adjustment is off in vanilla builds, but on when
feature = "test".

Voting rewards uses this new method. As long as the the new behavior is
not enabled (via the flag), this should result in no behavior change,
and even initially, when the feature is enabled, since no neuron can be
too unrefreshed, even then, there would be no immediate behavior change.

# Background

This is part of the "periodic confirmation" feature that was recently
approved in proposal [132411][prop].

[prop]: https://dashboard.internetcomputer.org/proposal/132411

# References

Closes https://dfinity.atlassian.net/browse/NNS1-3406,
https://dfinity.atlassian.net/browse/NNS1-3407.

[👈 Previous PR][prev] | [Next PR 👉][next]

[prev]: #2338
[next]: #2375
github-merge-queue Bot pushed a commit that referenced this pull request Feb 5, 2025
#2339

All changes here are comments.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants