Replies: 4 comments
-
|
Ad said earlier. This cannot be reproduced in localhost. I can successfully login when it have |
Beta Was this translation helpful? Give feedback.
-
|
Repository url if you need to check. |
Beta Was this translation helpful? Give feedback.
-
|
Closing this discussion as I switched to supabase |
Beta Was this translation helpful? Give feedback.
-
|
I run into the same original issue. Tripple checked GITHUB_SECRET, GITHUB_ID in Vercel environments vars, but still the same result: "Try signing in with a different account." |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Environment
{ "next": "^13.4.7", "next-auth": "^4.22.1", "react": "18.2.0" }Reproduction URL
https://github.com/Rahuletto/CodeBoard/tree/dev
Describe the issue
No access token provided error.
Double checked my GITHUB_SECRET, GITHUB_ID and it's correct.
https://codeboard-git-dev-rahuletto.vercel.app
When logging in, it will give
504 GATEWAY TIMEOUTand when looking into logs, this is what I got.[[next-auth][error][OAUTH_CALLBACK_ERROR] https://next-auth.js.org/errors#oauth_callback_error no access token provided { error: TypeError: no access token provided at Client.requestResource (/var/task/node_modules/openid-client/lib/client.js:1123:13) at Client.userinfo (/var/task/node_modules/openid-client/lib/client.js:1235:33) at Object.request (/var/task/node_modules/next-auth/providers/github.js:27:38) at oAuthCallback (/var/task/node_modules/next-auth/core/lib/oauth/callback.js:121:41) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async Object.callback (/var/task/node_modules/next-auth/core/routes/callback.js:52:11) at async AuthHandler (/var/task/node_modules/next-auth/core/index.js:208:28) at async NextAuthApiHandler (/var/task/node_modules/next-auth/next/index.js:22:19) at async NextAuth._args$ (/var/task/node_modules/next-auth/next/index.js:106:14) { name: 'OAuthCallbackError', code: undefined }, providerId: 'github', message: 'no access token provided' }Hosted on Vercel.
How to reproduce
Try signing in with a different account.NOTE:The auth worked when I use local host on my machine. But when deployed for preview in Vercel, it got broken apart and errors this instead. So you cannot reproduce it in local host.Expected behavior
Should authorize with GitHub and login successfully
Beta Was this translation helpful? Give feedback.
All reactions