Repository navigation
Bind the React Native authentication package to native DiditAuth - #63
Open
botinc-agent[bot] wants to merge 1 commit into
Open
botinc-agent[bot] wants to merge 1 commit into
botinc-agent[bot] wants to merge 1 commit into
Conversation
…ind to the shipped native DiditAuth API Opened by a BotInc run. Delivery follows the workflow's review and merge policy.
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
@didit-protocol/auth-react-nativenow calls native DiditAuth instead of rejecting every call. It replaces the placeholder boundary from #62.createDiditAuth({ publishableKey, redirectUri })returnssignIn,signInWithPasskey,registerPasskey,currentSession({ force }),getToken,signOutandstepUp({ action }).redirectUriis a required HTTPS address; native DiditAuth validates it.DiditAuth(context, publishableKey, redirectUri)per application and calls its suspend methods with the foreground activity. It depends onme.didit:didit-auth.DiditSDK/Auth(CocoaPods) or theDiditAuthproduct of sdk-ios (SwiftPM).cancelled,invalid_state,not_signed_in,passkey_cancelled,passkey_unavailable,browser_unavailable,rate_limitedand the API's own) reach JavaScript unchanged asDiditAuthError, withstatus,fieldsandretryAfterwhen present. Without the native module, every call rejects withERR_DIDIT_AUTH_UNAVAILABLE.didit-signalsanddidit-auth.Status: not ready, waiting for the native 4.10.0 release
The two native CI jobs fail on this PR and pass on
main. Both build the example against released native binaries, and 4.10.0 has not been released yet:Could not find me.didit:didit-sdk:4.10.0andme.didit:didit-auth:4.10.0didit-authordidit-signalsReactare missingNo code change can fix this:
didit-authexists in no released version, and the verification package must use the same native version as the authentication package (CocoaPods and SwiftPM resolve one DiditSDK version per app). Once sdk-android and sdk-ios carry 4.10.0, re-run both jobs on this head.Verification
Run locally on this head; every command exited 0:
yarn typecheck,yarn lintyarn test --runInBand: 17 suites, 158 tests passedyarn prepare,yarn build:auth,yarn workspace @didit-protocol/auth-react-native pack --dry-runyarn native:androidwithDIDIT_SDK_SOURCE_PATHat the pinned native revision: built and publisheddidit-auth4.10.0 and the other modules locally (JDK 17, Android SDK 36)example/android, against those artifacts:./gradlew :didit-protocol_auth-react-native:compileDebugKotlin :didit-protocol_auth-react-native:compileDebugJavaWithJavac :didit-protocol_sdk-react-native:compileDebugKotlin./gradlew app:assembleDebug -PreactNativeArchitectures=arm64-v8a: BUILD SUCCESSFUL. The debug APK contains the React Native module and native DiditAuthNot verified yet
DIDIT_SDK_SOURCE_PATHset to the pinned native revision.auth-react-native-v*tag is a placeholder until the package is published.Flutter
sdk-flutter has no
didit_authpackage; it needs its own package and pull request in that repository. That work also needs the 4.10.0 release, and this pull request does not change Flutter.No screens change, so there are no screenshots.
🤖 Generated with Claude Code