diff --git a/.github/workflows/canister-tests.yml b/.github/workflows/canister-tests.yml index 3c0d11fdcc..c2b3d140a3 100644 --- a/.github/workflows/canister-tests.yml +++ b/.github/workflows/canister-tests.yml @@ -955,23 +955,8 @@ jobs: steps: - uses: actions/checkout@v4 - uses: ./.github/actions/setup-didc - - name: 'Get latest release' - uses: actions/github-script@v7 - id: latest-release-tag - with: - result-encoding: string - script: return (await github.rest.repos.getLatestRelease({owner:"dfinity", repo:"internet-identity"})).data.tag_name; - name: "Check canister interface compatibility" run: | - release="release-2024-09-17" - # undo the breaking changes that we _explicitly_ made - # remove after the next release - # if we accidentally introduced other breaking changes, the patch would no longer apply / fix them - # making this job fail. - if [ "${{ steps.latest-release-tag.outputs.result }}" == "$release" ]; then - echo "Rolling back intentionally made breaking changes $release" - git apply allowed_breaking_change.patch - fi curl -sSL https://github.com/dfinity/internet-identity/releases/latest/download/internet_identity.did -o internet_identity_previous.did didc check src/internet_identity/internet_identity.did internet_identity_previous.did diff --git a/allowed_breaking_change.patch b/allowed_breaking_change.patch deleted file mode 100644 index ff53ba55a3..0000000000 --- a/allowed_breaking_change.patch +++ /dev/null @@ -1,121 +0,0 @@ -diff --git a/src/internet_identity/internet_identity.did b/src/internet_identity/internet_identity.did -index 500ef4d6..eb75b075 100644 ---- a/src/internet_identity/internet_identity.did -+++ b/src/internet_identity/internet_identity.did -@@ -435,6 +435,17 @@ type IdentityInfoError = variant { - InternalCanisterError: text; - }; - -+ -+ -+type IdentityRegisterError = variant { -+ // No more registrations are possible in this instance of the II service canister. -+ CanisterFull; -+ // The captcha check was not successful. -+ BadCaptcha; -+ // The metadata of the provided authentication method contains invalid entries. -+ InvalidMetadata: text; -+}; -+ - type AuthnMethodAddError = variant { - InvalidMetadata: text; - }; -@@ -521,72 +532,6 @@ type SignedIdAlias = record { - id_dapp : principal; - }; - --type IdRegNextStepResult = record { -- // The next step in the registration flow -- next_step: RegistrationFlowNextStep; --}; -- --type IdRegStartError = variant { -- // The method was called anonymously, which is not supported. -- InvalidCaller; -- // Too many registrations. Please try again later. -- RateLimitExceeded; -- // A registration flow is already in progress. -- AlreadyInProgress; --}; -- --// The next step in the registration flow: --// - CheckCaptcha: supply the solution to the captcha using `check_captcha` --// - Finish: finish the registration using `identity_registration_finish` --type RegistrationFlowNextStep = variant { -- // Supply the captcha solution using check_captcha -- CheckCaptcha: record { -- captcha_png_base64: text; -- }; -- // Finish the registration using identity_registration_finish -- Finish; --}; -- --type CheckCaptchaArg = record { -- solution : text; --}; -- --type CheckCaptchaError = variant { -- // The supplied solution was wrong. Try again with the new captcha. -- WrongSolution: record { -- new_captcha_png_base64: text; -- }; -- // This call is unexpected, see next_step. -- UnexpectedCall: record { -- next_step: RegistrationFlowNextStep; -- }; -- // No registration flow ongoing for the caller. -- NoRegistrationFlow; --}; -- --type IdRegFinishArg = record { -- authn_method: AuthnMethodData; --}; -- --type IdRegFinishResult = record { -- identity_number: nat64; --}; -- --type IdRegFinishError = variant { -- // The configured maximum number of identities has been reached. -- IdentityLimitReached; -- // This call is unexpected, see next_step. -- UnexpectedCall: record { -- next_step: RegistrationFlowNextStep; -- }; -- // No registration flow ongoing for the caller. -- NoRegistrationFlow; -- // The supplied authn_method is not valid. -- InvalidAuthnMethod: text; -- // Error while persisting the new identity. -- StorageError: text; --}; -- - service : (opt InternetIdentityInit) -> { - // Legacy identity management API - // ============================== -@@ -613,17 +558,16 @@ service : (opt InternetIdentityInit) -> { - - // V2 Identity Management API - // ========================== -- // WARNING: The following methods are experimental and may ch 0ange in the future. -- -- // Starts the identity registration flow to create a new identity. -- identity_registration_start: () -> (variant {Ok: IdRegNextStepResult; Err: IdRegStartError;}); -+ // WARNING: The following methods are experimental and may change in the future. - -- // Check the captcha challenge -- // If successful, the registration can be finished with `identity_registration_finish`. -- check_captcha: (CheckCaptchaArg) -> (variant {Ok: IdRegNextStepResult; Err: CheckCaptchaError;}); -+ // Creates a new captcha. The solution needs to be submitted using the -+ // `identity_register` call. -+ captcha_create: () -> (variant {Ok: Challenge; Err;}); - -- // Starts the identity registration flow to create a new identity. -- identity_registration_finish: (IdRegFinishArg) -> (variant {Ok: IdRegFinishResult; Err: IdRegFinishError;}); -+ // Registers a new identity with the given authn_method. -+ // A valid captcha solution to a previously generated captcha (using create_captcha) must be provided. -+ // The sender needs to match the supplied authn_method. -+ identity_register: (AuthnMethodData, CaptchaResult, opt principal) -> (variant {Ok: IdentityNumber; Err: IdentityRegisterError;}); - - // Returns information about the authentication methods of the identity with the given number. - // Only returns the minimal information required for authentication without exposing any metadata such as aliases.