-
Notifications
You must be signed in to change notification settings - Fork 336
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
feat(nns): Add neuron_minimum_dissolve_delay_to_vote_seconds
to VotingPowerEconomics
#4180
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this pull request affects the behavior of any canister owned by
the Governance team, remember to update the corresponding
unreleased_changes.md file(s).
To acknowldge this reminder (and unblock the PR), dismiss this
code review by going to the bottom of the pull request page, and
supply one of the following reasons:
-
Done.
-
No canister behavior changes.
pub const MIN_DISSOLVE_DELAY_FOR_VOTE_ELIGIBILITY_SECONDS_BOUNDS: RangeInclusive<u64> = | ||
(3 * ONE_MONTH_SECONDS)..=(6 * ONE_MONTH_SECONDS); | ||
|
||
if !MIN_DISSOLVE_DELAY_FOR_VOTE_ELIGIBILITY_SECONDS_BOUNDS.contains(&delay) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm confused by this - why not just do >= and <= instead of constructing a range and seeing if the value is inside of it?
/// This value is an essential part of the staking mechanism, promoting | ||
/// long-term alignment with the network's governance. | ||
#[prost(uint64, optional, tag = "3")] | ||
pub neuron_minimum_dissolve_delay_to_vote_seconds: ::core::option::Option<u64>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So my main question is - if we're exposing this as an API parameter, does that mean that the value is actually being used to see if a neuron can vote? It looks like not yet. Is there a followup PR planned to actually use the value on VotingPowerEconomics to determine neuron voting eligibility?
This PR moves the inner code constant
neuron_minimum_dissolve_delay_to_vote_seconds
toVotingPowerEconomics
, exposing it as an API parameter. This helps the NNS clients to prepare for a potential change of this parameter.