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

feat(nns): Define update_canister_settings proposal type without execution #529

Merged
merged 4 commits into from
Jul 25, 2024

Conversation

jasonz-dfinity
Copy link
Contributor

Why

Support a new proposal type to call ic0.update_settings for a canister controlled by NNS Root. This can be used to update memory_allocation, controllers, log_visibility, etc.

What

  • Define such proposals
  • Validation for the proposal type
  • Disabling on the mainnet, so such proposals cannot be created until downstream is ready
  • A state machine test to make sure proposals can be created (although we expect it to fail to execute)

Caveats

Due to how types in the NNS Governance is structured (proto -> rs -> candid), we are unable to create candid::Nat fields in a way that's easy to use by clients (protobuf doesn't have integer fields larger than uint64). For this reason, we do not support reserved_cycles_limit for now, since it is measured in # of cycles and has a range of u128. In the near future, we should be able to decouple the API types from the internal types, so that the API type can be nat, while the storage can be message Cycles { bytes raw_bytes = 1 }.

@jasonz-dfinity jasonz-dfinity requested a review from a team as a code owner July 22, 2024 21:59
@github-actions github-actions bot added the feat label Jul 22, 2024
@jasonz-dfinity jasonz-dfinity added this pull request to the merge queue Jul 24, 2024
@jasonz-dfinity jasonz-dfinity removed this pull request from the merge queue due to a manual request Jul 24, 2024
@jasonz-dfinity jasonz-dfinity enabled auto-merge July 24, 2024 23:02
@jasonz-dfinity jasonz-dfinity added this pull request to the merge queue Jul 25, 2024
Merged via the queue into master with commit 2b109fb Jul 25, 2024
22 checks passed
@jasonz-dfinity jasonz-dfinity deleted the jason/NNS1-2522-1 branch July 25, 2024 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants