Open
Description
Environment
System:
OS: macOS 15.3.1
CPU: (8) arm64 Apple M2
Memory: 1.02 GB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.14.0 - ~/.nvm/versions/node/v22.14.0/bin/node
npm: 11.1.0 - ~/.nvm/versions/node/v22.14.0/bin/npm
Watchman: 2024.12.02.00 - /opt/homebrew/bin/watchman
Browsers:
Safari: 18.3
npmPackages:
@auth/prisma-adapter: ^2.8.0 => 2.8.0
next: 15.2.0 => 15.2.0
next-auth: ^5.0.0-beta.25 => 5.0.0-beta.25
react: ^19.0.0 => 19.0.0
Reproduction URL
https://github.com/th3f0r3ign3r/authjs-issue.git
Describe the issue
I have setting up Auth.js with Github Oauth and I decided to add PrismaAdapter with (mongodb) to save user account information. Without adding the adapter everything working great. But when I added the Adapter to @/auth
it crash
CleanShot.2025-03-04.at.19.35.44.mp4
How to reproduce
- Clone the project
- Create a Github App (CLIENT_ID & CLIENT_SECRET)
- Create a MongoBD account and get a connection string
- Add them to the .env.local & run
npx prisma generate
- Go to
src/auth/index.ts
comment the adapters line - Launch the project
clear && npm run dev
don’t forget to runnpm i
- Click on the
Signin with GitHub
- After being logged signOut
- Uncomment the adapter line
- Refresh your browser
If you follow all these steps normally you will have the same error
Expected behavior
Normally they should not have any error. Instead I am doing something wrong but I follow the guide line per line. 😩😩😩