Repository navigation
fix(expo): show a clear error when the native build doesn't match @clerk/expo - #11011
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
🦋 Changeset detectedLatest commit: cb6dfbc The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@clerk/astro
@clerk/backend
@clerk/chrome-extension
@clerk/clerk-js
@clerk/electron
@clerk/electron-passkeys
@clerk/eslint-plugin
@clerk/expo
@clerk/expo-biometrics
@clerk/expo-google-signin
@clerk/expo-native-components
@clerk/expo-passkeys
@clerk/express
@clerk/fastify
@clerk/hono
@clerk/localizations
@clerk/mosaic
@clerk/nextjs
@clerk/nuxt
@clerk/react
@clerk/react-router
@clerk/shared
@clerk/tanstack-react-start
@clerk/testing
@clerk/ui
@clerk/upgrade
@clerk/vue
commit: |
… version in the contract test
|
API Changes Report
Summary
No API Changes DetectedAll packages have stable APIs with no detected changes. Report generated by Break Check Last ran on |
…ridge versions match



Description
When an app's native build doesn't match
@clerk/expo, the native components render blank.@clerk/expoonly noticed when a native method was missing, and logged it only in development. So a release build that got a newer@clerk/expothrough an over-the-air update failed silently. A method that kept its name but changed its arguments wasn't caught at all.The native module in
@clerk/expo-native-componentsnow exports abridgeVersionconstant, and@clerk/expochecks it against the version it expects. On a mismatch it disables native components and logs an error in every build that names the@clerk/expoversion and tells you to update both packages together and rebuild. Native builds from before this change don't export the constant, so they count as version 1 when they have the current methods. The next change to the contract between the two packages bumps the number on both sides, and the native contract test fails if Swift, Kotlin and@clerk/expodisagree.The screenshots are development builds with a local patch, not committed, that stands in for the next contract change. It adds an argument to the native
configureNativeand setsbridgeVersionto 2 on both builds. Before,@clerk/expoonly logs a Metro warning that configuring native failed (Received 3 arguments, but 4 was expected) and the sign-in view is empty. After, the app shows the error. Device e2e also passed on iOS and Android with no patch.Fixes MOBILE-729.
Checklist
pnpm testruns as expected.pnpm buildruns as expected.Type of change
🤖 Generated with Claude under Rob's supervision.