Skip to content

chore: Fix candid encoding for II upgrade args#3641

Merged
aterga merged 2 commits intomainfrom
arhsvair/fix-candid-arg-encoding
Mar 2, 2026
Merged

chore: Fix candid encoding for II upgrade args#3641
aterga merged 2 commits intomainfrom
arhsvair/fix-candid-arg-encoding

Conversation

@aterga
Copy link
Contributor

@aterga aterga commented Feb 28, 2026

Motivation

This PR ensures that the Candid encoding of II install arguments takes API type definitions into account. Candid encoding should use the correct type definitions, not automatically inferred types, otherwise distinct variant cases may get unexpectedly collapsed into one.

Changes

Provide options -d ./src/internet_identity/internet_identity.did -t '(opt InternetIdentityInit)' to all candid commands in the upgrade script.

Tests

Tested manually.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the release SOP script used to deploy an Internet Identity (II) release candidate and generate/verify upgrade arguments, aiming to ensure the Candid upgrade args are encoded correctly for upgrades.

Changes:

  • Switches upgrade-arg encoding to didc encode -d ... -t ... to force the intended type during encoding.
  • Adjusts the dfx canister install invocation to use --argument-type raw and consume a generated argument artifact.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@aterga aterga marked this pull request as ready for review March 2, 2026 09:57
Copy link
Contributor

@sea-snake sea-snake left a comment

Choose a reason for hiding this comment

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

LGTM

@aterga aterga added this pull request to the merge queue Mar 2, 2026
Merged via the queue into main with commit 577f108 Mar 2, 2026
63 checks passed
@aterga aterga deleted the arhsvair/fix-candid-arg-encoding branch March 2, 2026 16:23
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.

3 participants