better-auth@1.4.7 is conflict with prisma@7.2.0 #2585

Closed
opened 2026-03-13 10:04:55 -05:00 by GiteaMirror · 5 comments
Owner

Originally created by @Chavda2772 on GitHub (Dec 21, 2025).

Is this suited for github?

  • Yes, this is suited for github

To Reproduce

Steps to recreate this issue.

  1. Install prisma@latest (7.2.0).
  2. Try to install better-auth@latest (1.4.7)

Not able to install better-auth it throw an error

E:\WebApplication\Github\Settlr>npm install better-auth@latest
npm error code ERESOLVE
npm error ERESOLVE unable to resolve dependency tree
npm error
npm error While resolving: settlr@0.1.0
npm error Found: prisma@7.2.0
npm error node_modules/prisma
npm error dev prisma@"^7.2.0" from the root project
npm error peerOptional prisma@"" from @prisma/client@7.2.0
npm error node_modules/@prisma/client
npm error @prisma/client@"^7.2.0" from the root project
npm error peerOptional @prisma/client@"
" from drizzle-orm@0.41.0
npm error node_modules/drizzle-orm
npm error peerOptional drizzle-orm@"^0.41.0" from better-auth@1.4.7
npm error node_modules/better-auth
npm error better-auth@"1.4.7" from the root project
npm error
npm error Could not resolve dependency:
npm error peerOptional prisma@"^5.22.0" from better-auth@1.4.7
npm error node_modules/better-auth
npm error better-auth@"1.4.7" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.

Current vs. Expected behavior

Currently it throw an error.

What version of Better Auth are you using?

1.4.7

System info

1.4.7

Which area(s) are affected? (Select all that apply)

Package

Auth config (if applicable)

import { betterAuth } from "better-auth"
export const auth = betterAuth({
  emailAndPassword: {  
    enabled: true
  },
});

Additional context

No response

Originally created by @Chavda2772 on GitHub (Dec 21, 2025). ### Is this suited for github? - [ ] Yes, this is suited for github ### To Reproduce Steps to recreate this issue. 1. Install prisma@latest (7.2.0). 2. Try to install better-auth@latest (1.4.7) Not able to install better-auth it throw an error ========================================== E:\WebApplication\Github\Settlr>**npm install better-auth@latest** npm error code ERESOLVE npm error ERESOLVE unable to resolve dependency tree npm error npm error While resolving: settlr@0.1.0 npm error Found: prisma@7.2.0 npm error node_modules/prisma npm error dev prisma@"^7.2.0" from the root project npm error peerOptional prisma@"*" from @prisma/client@7.2.0 npm error node_modules/@prisma/client npm error @prisma/client@"^7.2.0" from the root project npm error peerOptional @prisma/client@"*" from drizzle-orm@0.41.0 npm error node_modules/drizzle-orm npm error peerOptional drizzle-orm@"^0.41.0" from better-auth@1.4.7 npm error node_modules/better-auth npm error better-auth@"1.4.7" from the root project npm error npm error Could not resolve dependency: npm error peerOptional prisma@"^5.22.0" from better-auth@1.4.7 npm error node_modules/better-auth npm error better-auth@"1.4.7" from the root project npm error npm error Fix the upstream dependency conflict, or retry npm error this command with --force or --legacy-peer-deps npm error to accept an incorrect (and potentially broken) dependency resolution. ### Current vs. Expected behavior Currently it throw an error. ### What version of Better Auth are you using? 1.4.7 ### System info ```bash 1.4.7 ``` ### Which area(s) are affected? (Select all that apply) Package ### Auth config (if applicable) ```typescript import { betterAuth } from "better-auth" export const auth = betterAuth({ emailAndPassword: { enabled: true }, }); ``` ### Additional context _No response_
GiteaMirror added the dependencies label 2026-03-13 10:04:55 -05:00
Author
Owner

@better-auth-agent[bot] commented on GitHub (Dec 21, 2025):

You are experiencing a dependency conflict between better-auth@1.4.7 and prisma@7.2.0. The relevant issue indicates that better-auth@1.4.7 has a peer dependency requirement for prisma of version ^5.22.0, which contradicts the version you are trying to install [2].

Here are the next steps you can take to resolve this issue:

  1. Check for Compatibility: Since better-auth@1.4.7 does not officially support prisma@7.2.0, consider downgrading prisma to a version that is compatible with better-auth, such as versions >=5.22.0 but <6.0.0.

  2. Use npm Options: Alternatively, you can try installing with either --force or --legacy-peer-deps options if you want to bypass the peer dependency resolution, although this may lead to unexpected behaviors.

  3. Monitor GitHub Discussions: If you want to keep up with updates on this situation or suggest that better-auth supports newer versions of Prisma, opening an issue on GitHub or checking existing issues related to this topic could be beneficial.

Would you like help with something else, or do you have specific questions about the installation process?

If you need more help, tag @better-auth-agent in a comment so I can respond.

DiagramDiscordGitHub

Diagram Join Star

@better-auth-agent[bot] commented on GitHub (Dec 21, 2025): You are experiencing a dependency conflict between `better-auth@1.4.7` and `prisma@7.2.0`. The relevant issue indicates that `better-auth@1.4.7` has a peer dependency requirement for `prisma` of version `^5.22.0`, which contradicts the version you are trying to install [[2]](https://github.com/better-auth/better-auth/issues/6870). Here are the next steps you can take to resolve this issue: 1. **Check for Compatibility**: Since `better-auth@1.4.7` does not officially support `prisma@7.2.0`, consider downgrading `prisma` to a version that is compatible with `better-auth`, such as versions >=5.22.0 but <6.0.0. 2. **Use npm Options**: Alternatively, you can try installing with either `--force` or `--legacy-peer-deps` options if you want to bypass the peer dependency resolution, although this may lead to unexpected behaviors. 3. **Monitor GitHub Discussions**: If you want to keep up with updates on this situation or suggest that better-auth supports newer versions of Prisma, opening an issue on GitHub or checking existing issues related to this topic could be beneficial. Would you like help with something else, or do you have specific questions about the installation process? _If you need more help, tag @better-auth-agent in a comment so I can respond._ <!-- bot:webhook reply v1 --> [Diagram](https://repodiagrams.s3.eu-north-1.amazonaws.com/skyvern_ultra_detailed_interactive.html) • [Discord](https://discord.gg/fG2XXEuQX3) • [GitHub](https://github.com/Skyvern-AI/Skyvern) [![Diagram](https://img.shields.io/badge/Diagram-2b3137?style=flat-square)](https://repodiagrams.s3.eu-north-1.amazonaws.com/skyvern_ultra_detailed_interactive.html) [![Join](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&style=flat-square)](https://discord.gg/fG2XXEuQX3) [![Star](https://img.shields.io/badge/star-181717?logo=github&logoColor=white&style=flat-square)](https://github.com/Skyvern-AI/Skyvern)
Author
Owner

@tavongamatikiti commented on GitHub (Dec 21, 2025):

You can try v1.4.8-beta.1 and it is fixed in 00ede9037a

@tavongamatikiti commented on GitHub (Dec 21, 2025): You can try v1.4.8-beta.1 and it is fixed in https://github.com/better-auth/better-auth/commit/00ede9037a4bce5f48f9adc0bc01d6e34056af3c
Author
Owner

@RockyAiii commented on GitHub (Dec 22, 2025):

Just want to tag in that i upgraded to prisma 7.2.0 earlier on . Everything was sweet with better-auth 1.4.5 and prisma 7.1.0 though a few niggles still going with prisma but could log in all fine. Soon as i went to 7.2.0, could not log in at all. Went to upgrade better-auth and ran into the same issue as above. I've just tried 1.4.8-beta-1 which installed fine but still can't log in. I get a log of these errors Error: sourceMapURL could not be parsed.

@RockyAiii commented on GitHub (Dec 22, 2025): Just want to tag in that i upgraded to prisma 7.2.0 earlier on . Everything was sweet with better-auth 1.4.5 and prisma 7.1.0 though a few niggles still going with prisma but could log in all fine. Soon as i went to 7.2.0, could not log in at all. Went to upgrade better-auth and ran into the same issue as above. I've just tried 1.4.8-beta-1 which installed fine but still can't log in. I get a log of these errors Error: sourceMapURL could not be parsed.
Author
Owner

@himself65 commented on GitHub (Dec 22, 2025):

You can try v1.4.8-beta.1 and it is fixed in 00ede9037a

Closing

@himself65 commented on GitHub (Dec 22, 2025): You can try v1.4.8-beta.1 and it is fixed in https://github.com/better-auth/better-auth/commit/00ede9037a4bce5f48f9adc0bc01d6e34056af3c Closing
Author
Owner

@Chavda2772 commented on GitHub (Dec 22, 2025):

Hi @RockyAiii ,
Better-auth@1.4.5 and
Prisma@7.1.0

works for me.
@himself65
Once better-auth@1.4.8 release I will upgrade.

Thank you
@RockyAiii and @himself65

@Chavda2772 commented on GitHub (Dec 22, 2025): Hi @RockyAiii , Better-auth@1.4.5 and Prisma@7.1.0 works for me. @himself65 Once better-auth@1.4.8 release I will upgrade. Thank you @RockyAiii and @himself65
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#2585