W
Wasp2w ago
Sahee

http://localhost:3001/auth/me is constantly pending

http://localhost:3001/auth/me is constantly pending and i can't debug that as no errors show in the console
3 Replies
kapa.ai
kapa.ai2w ago
Hi @Sahee. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- A constantly “pending” /auth/me usually means the browser can’t reach your Wasp server (port 3001) or the request is blocked/misrouted, so the client keeps waiting. Here are the concrete checks and fixes gathered from similar cases: - Ensure server is actually reachable on 3001: - Wasp runs client on 3000 and server on 3001. If 3001 is occupied or unreachable, requests hang. Free up 3000 and 3001 before running wasp start. [Frontend ports] - If you’re calling the server from scripts or tools, target port 3001. [JWT example] - If you’re using a tunnel or remote dev (ngrok, Gitpod, Fly.io): - Set REACT_APP_API_URL in .env.client to the public URL of your server, not localhost. For ngrok, forward both 3000 and 3001 and set REACT_APP_API_URL to the 3001 tunnel URL. [Ngrok setup; Ngrok env var] - On Gitpod, open port 3001 and set both WASP_WEB_CLIENT_URL in .env.server and REACT_APP_API_URL in .env.client to the Gitpod URLs (e.g., https://3001-…gitpod.io). [Gitpod vars; Gitpod CORS symptom] - If you open the ngrok link on another device (e.g., phone), it can’t reach your local 3001 unless you also tunnel it and point REACT_APP_API_URL to that tunneled server. [Ngrok cross-device] - Check for CORS or misconfigured URLs: - A missing Access-Control-Allow-Origin on remote setups indicates your client is still pointing to localhost:3001. Update REACT_APP_API_URL and restart. [Gitpod CORS] - Using 127.0.0.1 instead of localhost can help on some machines. [Ngrok tip] - Look for server-side errors even if the browser shows none: - Open your server logs; if the server crashed or is waiting for misconfigured auth (e.g., missing Google client ID/secret), requests will stall. [OAuth env error] - On Fly.io, slow or non-responsive server made isUserLoading stay true and login spin; redeploying fixed it—pointing to server unresponsiveness rather than client code. [Fly.io case] Quick checklist: 1) Confirm wasp start shows both client (3000) and server (3001) running. [Frontend ports] 2) If not purely local, set REACT_APP_API_URL to your server’s public URL and restart. 3) For social auth, ensure required env vars (e.g., Google client ID/secret) are in .env.server; missing vars can break auth init. [OAuth env error] 4) If using ngrok, tunnel both 3000 and 3001 and set REACT_APP_API_URL to the 3001 tunnel. [Ngrok env var] 5) Try 127.0.0.1 instead of localhost. [Ngrok tip] If you share your environment (local vs Gitpod/ngrok/Fly), your .env.client REACT_APP_API_URL value, and any server log output, I can help pinpoint the exact cause. ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ---------------------- Sorry @Sahee, I seem to be having a bit of trouble. Don't worry though, I've pinged my support and they will try to fix me up! :technologist: Perhaps try again in 15mins?
Sahee
SaheeOP2w ago
A simple browser restart helped
miho
miho2w ago
@Sahee I'm glad it was something simple like that!

Did you find this page helpful?