feat: WIP-102 update/revert recovery agent#381
Draft
Kemperino wants to merge 4 commits into
Draft
Conversation
Adds the V2 recovery-agent flow from WIP-102 and deprecates the V1 flow. New `update_recovery_agent` and `revert_recovery_agent_update` wrappers delegate to the SDK's V2 methods. The three V1 wrappers (`initiate_/execute_/cancel_recovery_agent_update`) are kept for backward compat but marked `#[deprecated]`; the SDK marks the underlying methods deprecated too, so the call-site bodies need `#[allow(deprecated)]`. Module-level `#![allow(deprecated)]` is required in `authenticator/mod.rs` because `#[uniffi::export]` generates FFI registrations outside the impl-level lint scope and references the deprecated method names. Updates `walletkit recovery-agent` CLI subcommands from `Initiate/Execute/Cancel` to `Update/Revert` (Execute is dropped — V2 has no execute step; the underlying SDK call is a no-op on a V2-upgraded gateway). WIP-104 verified to have no walletkit impact: the only Rust SDK change is a doc-comment rewording in primitives/lib.rs. Pinned to upstream wip-102 git branch until WIP-102 ships in a world-id-core release; flip to version pin then. Refs: worldcoin/world-id-protocol#692, worldcoin/world-id-protocol#643 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
9f942ac to
3ac6f9f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds the WIP-102 V2 recovery-agent flow to walletkit and deprecates the V1 flow.
Authenticator::update_recovery_agent(new_recovery_agent: String)— V2 replacement forinitiate_recovery_agent_update. Effective immediately with a revert window instead of a 14-day cooldown.Authenticator::revert_recovery_agent_update()— V2 replacement forcancel_recovery_agent_update. Reuses the same EIP-712 typehash; only the gateway endpoint differs.initiate_/execute_/cancel_recovery_agent_update) with#[deprecated]. Kept for backward compatibility — Swift/Kotlin consumers continue to compile.walletkit recovery-agentsubcommands updated:Initiate/Execute/Cancel→Update/Revert.Executeis dropped —Notable implementation detail
Module-level `#![allow(deprecated)]` is required in `walletkit-core/src/authenticator/mod.rs` because `#[uniffi::export]` generates FFI registrations outside the impl-level lint scope and references the deprecated method names — which would otherwise emit warnings at the V1 wrapper definition sites and fail `-D warnings` in CI.
Why draft
This branch points at the upstream `wip-102` git branch for `world-id-core` and `world-id-proof`. CI will fail until upstream merges WIP-102 and cuts a release