Repository navigation
Upgrade @clerk/nextjs to v7 (Clerk Core 3) - #16
jayypatel18 wants to merge 1 commit into
Conversation
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (5)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe Clerk dependency range changes from ChangesClerk v7 compatibility
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Change: Other Suggested reviewers: Merge Risk: 🔵 Low · up to The Clerk v7 upgrade looks mechanically consistent. Before merging, click through sign-in, sign-up and the OAuth callback on a preview deploy, and confirm the hosting runtime is Node 20.9 or later. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to The application retains fixed redirect destinations and activates sessions only after completed verification. No introduced authorization bypass was established. However, authentication failure, replay, and recovery behavior have not been demonstrated against a real Clerk instance, so risk is not minimal. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
Hardening Proposals
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 4 files. (1 skipped: 1 unsupported.)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Hi nicuk, A gentle follow up on this PR. It upgrades your clerk package to the latest supported package before EOL of current package. Once you get time kindly take a look at this PR, your time is much appreciated! Thanks, |
DocsFlow is on
@clerk/nextjs6, which is Clerk Core 2. Clerk's schedule ends long term support for Core 2 in January 2027. Core 3 needs Next.js 15.2.8 or later and Node 20.9 or later. The repo is on Next.js 15.5.12 and CI runs Node 20, so only Clerk moves.What changed
package.json,package-lock.json:@clerk/nextjs^6.33.0to^7.0.0(resolves to 7.9.9).components/login-page.tsx,components/signup-page.tsx,app/verify-email/page.tsx:useSignInanduseSignUpnow come from@clerk/nextjs/legacy. Core 3 gave these hooks a new return shape; the/legacyentry point keeps the shape the custom login, signup and verify-email forms are written against, so the forms themselves are untouched.app/sso-callback/page.tsx:handleRedirectCallbackno longer takesafterSignInUrlandafterSignUpUrl. They becomesignInFallbackRedirectUrlandsignUpFallbackRedirectUrl, both still/onboarding.What I checked
In a clean Node 20 container, on
mainand then on this branch, with install scripts off:npm cinpm test(the CI job)tsc --noEmitAll 116 type errors are in four test files (
test/rag-multimodal-parser.test.ts,test/auth-integration.test.ts,app/api/onboarding/complete/route.test.ts,lib/ai/providers.test.ts) that use Jest globals without types. The application code type-checks clean on both sides.Not checked: sign-in, sign-up and the OAuth callback against a real Clerk instance. Those are the flows this PR touches, so they are worth a click-through on a preview deploy before merging.
Worth a look
/legacyhooks are Clerk's supported way to keep the old flow working in Core 3. Moving the three forms to the new hook API is a separate, larger change.getToken()throwsClerkOfflineErrorwhen the browser is offline instead of returningnull.Summary by CodeRabbit