S
Supabase2mo ago
Maher

How to not log the auth errors

I'm using nextjs app router + supabase auth when the refresh token is expired the auth errors are being logged in the server logs, does supabase js log them internally? because I can't seem to catch and handle these errors: AuthApiError: Invalid Refresh Token: Refresh Token Not Found at dk (.next/server/src/middleware.js:33:29611) at async dm (.next/server/src/middleware.js:33:30585) at async dl (.next/server/src/middleware.js:33:29995) at async c (.next/server/src/middleware.js:33:66145) at async (.next/server/src/middleware.js:33:66408) { __isAuthError: true, status: 400, code: 'refresh_token_not_found' }
3 Replies
DevilsBlade0
DevilsBlade02mo ago
Really think service is down
silentworks
silentworks2mo ago
These can no longer be caught, there was some changes to the @supabase/auth-js library some years back which stops you from actually catching this error. So no it always get logged in the console.
Maher
MaherOP2mo ago
I'm getting like 200k logs per minute because of this!

Did you find this page helpful?