422 - USER_ALREADY_EXISTS_USE_ANOTHER_EMAIL.... But they shouldn't?

Hi! Thanks for looking at my question.

I've set better-auth up prior, and have been able to create and login with users before.

I recently wiped my database so that I could do some in-depth testing surrounding authentication in my work flows.

When I go to create an account with the email I used pre-wipe (jacktfennis@gmail.com), I get the error:

{code: 'USER_ALREADY_EXISTS_USE_ANOTHER_EMAIL', message: 'User already exists. Use another email.', status: 422, statusText: 'UNPROCESSABLE_ENTITY'}


This is confusing - because in the auth.ts file, the one where I set up the pool to be passed to betterAuth, I log each table. Here are the results of the logging:

postgresql://postgres:a@localhost:5432/local-database
2025-09-14T22:37:34.651Z INFO [Better Auth]: Sign-up attempt for existing email: jacktfennis@gmail.com
 POST /api/auth/sign-up/email 422 in 1225ms
From USER:  [ { user: 'postgres' } ]
From ACCOUNTL  []
From SESSION:  []
From VERIFICATION:  []


Here is the auth.ts file in question:
https://bin.mudfish.net/t/869-4695-3831

What could the issue be? It seems like the users are being stored internally somewhere, but I haven't found anything that says that in the documentation.

Thanks!
Was this page helpful?