Content-Length: 334772 | pFad | https://github.com/nextauthjs/next-auth/pull/13061

FA fix(adapters): handle P2025 errors without importing Prisma namespace by karl-barbour · Pull Request #13061 · nextauthjs/next-auth · GitHub
Skip to content

fix(adapters): handle P2025 errors without importing Prisma namespace #13061

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 22, 2025

Conversation

karl-barbour
Copy link
Contributor

@karl-barbour karl-barbour commented Jun 20, 2025

☕️ Reasoning

A bug relating to importing Prisma from a custom output raised in #13060 seems to be caused by previous PR #12755 where functionality was changed to import the error class PrismaClientKnownRequestError from the Prisma namespace.

As we are only looking for code P2025 (defined here) we do not need to import the full client.

🧢 Checklist

  • Documentation
  • Tests
  • Ready to be merged

🎫 Affected issues

Fixes: #13060 #13035

📌 Resources

@karl-barbour karl-barbour requested a review from ndom91 as a code owner June 20, 2025 14:08
Copy link

vercel bot commented Jun 20, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
auth-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 22, 2025 10:39am
1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
next-auth-docs ⬜️ Ignored (Inspect) Visit Preview Jun 22, 2025 10:39am

Copy link

vercel bot commented Jun 20, 2025

@karl-barbour is attempting to deploy a commit to the authjs Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions bot added adapters Changes related to the core code concerning database adapters prisma @auth/prisma-adapter labels Jun 20, 2025
Copy link

codecov bot commented Jun 22, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 39.42%. Comparing base (29de85b) to head (0dc3df3).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #13061   +/-   ##
=======================================
  Coverage   39.41%   39.42%           
=======================================
  Files         200      200           
  Lines       31780    31782    +2     
  Branches     1393     1399    +6     
=======================================
+ Hits        12527    12529    +2     
  Misses      19253    19253           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ThangHuuVu
Copy link
Member

Thanks for the fix!

@ThangHuuVu ThangHuuVu merged commit 9866f71 into nextauthjs:main Jun 22, 2025
12 of 14 checks passed
@yusifaliyevpro
Copy link

Thanks again

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
adapters Changes related to the core code concerning database adapters prisma @auth/prisma-adapter
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Prisma adapter does not work with custom output path
3 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/nextauthjs/next-auth/pull/13061

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy