refactor: add missing IWorldIDVerifierV2 interface - #863
Closed
kilianglas wants to merge 1 commit into
Closed
Conversation
Contributor
Author
|
Superseded: the V2 interface will be introduced together with verifyWithSession in #862 instead. |
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
WorldIDVerifierV2is the only versioned core contract without a matching versioned interface —WorldIDRegistryV2pairs withIWorldIDRegistryV2 is IWorldIDRegistry, while the verifier V2 declares itsInvalidActionerror directly on the contract. This adds the missingIWorldIDVerifierV2so the verifier follows the same pattern, and so future verifier versions (e.g. a V3 adding new entry points) have a proper interface chain to extend.IWorldIDVerifierV2 is IWorldIDVerifier: declaresInvalidActionand documents V2's action-prefix semantics (verifyrequires MSB0x00,verifySessionrequires0x02).WorldIDVerifierV2 is IWorldIDVerifierV2, WorldIDVerifier(mirrorsWorldIDRegistryV2): local error declaration removed; overrides now name both bases (override(IWorldIDVerifier, WorldIDVerifier)), as required by the diamond inheritance and consistent with the registry.IWorldIDVerifierV2.InvalidAction.selector), matching the registry test idiom.@title WorldIDVerifieron the V2 contract.No behavior change: same functions, same checks, same error selector.
Test plan
cd contracts && forge test— 331 tests green