[GH-ISSUE #306] Localhost remains in the same state(not responding) #178

Closed
opened 2026-02-22 18:18:15 -05:00 by yindo · 3 comments
Owner

Originally created by @Krisvanth on GitHub (Oct 28, 2023).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/306

Hi,
I'm trying to deploy this in my local using the instructions provided in the documentation. Once the setup is done I tried to execute these commands yarn dev:server and yarn dev:frontend. Recieved success in terminal for both the commands but when I tried to open the localhost link it is in the same state for a while. I uploaded the screenshot here.

This is the error from console:
index.jsx:21 Uncaught (in promise) TypeError: Cannot destructure property 'MultiUserMode' of '(intermediate value)' as it is null.
at validateSession (index.jsx:21:9)

image

Originally created by @Krisvanth on GitHub (Oct 28, 2023). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/306 Hi, I'm trying to deploy this in my local using the instructions provided in the documentation. Once the setup is done I tried to execute these commands yarn dev:server and yarn dev:frontend. Recieved success in terminal for both the commands but when I tried to open the localhost link it is in the same state for a while. I uploaded the screenshot here. This is the error from console: index.jsx:21 Uncaught (in promise) TypeError: Cannot destructure property 'MultiUserMode' of '(intermediate value)' as it is null. at validateSession (index.jsx:21:9) ![image](https://github.com/Mintplex-Labs/anything-llm/assets/88583624/ea4795b3-44e4-402c-9615-8c43ad3b8a0c)
yindo closed this issue 2026-02-22 18:18:15 -05:00
Author
Owner

@timothycarambat commented on GitHub (Oct 29, 2023):

So it seems like the backend may not be running correctly since the call to the API fails?

When you open the browser inspector and go to Network and reload the tab what does the call to ${API_BASE}/setup-complete output? 400, 500?

Two things off the top I can see occurring:

  • Frontend is trying to talk to the API on 3001 but URL is not reachable
    • what URL is it trying to reach? Should be localhost:3001/api/setup-complete
  • Backend did actually not boot successfully because DB either...
    • does not exist (make sure server/storage/anythingllm.db exists)
    • in project root directory run yarn prisma:migrate and reboot backend.
@timothycarambat commented on GitHub (Oct 29, 2023): So it seems like the backend may not be running correctly since the call to the API fails? When you open the browser inspector and go to Network and reload the tab what does the call to `${API_BASE}/setup-complete` output? 400, 500? Two things off the top I can see occurring: - Frontend is trying to talk to the API on 3001 but URL is not reachable - what URL is it trying to reach? Should be `localhost:3001/api/setup-complete` - Backend did actually not boot successfully because DB either... - does not exist (make sure `server/storage/anythingllm.db` exists) - in project root directory run `yarn prisma:migrate` and reboot backend.
Author
Owner

@AlexeySchegolev commented on GitHub (Oct 29, 2023):

I'm getting the same issue. The setup-complete responses with 200. The preview of the response is on the screenshot. The console displays the reported error. Server, frontend, collector terminals are showing no errors.
grafik

@AlexeySchegolev commented on GitHub (Oct 29, 2023): I'm getting the same issue. The setup-complete responses with 200. The preview of the response is on the screenshot. The console displays the reported error. Server, frontend, collector terminals are showing no errors. <img width="1449" alt="grafik" src="https://github.com/Mintplex-Labs/anything-llm/assets/99136050/86b59612-799d-4846-9bdb-824b12b7d97e">
Author
Owner

@timothycarambat commented on GitHub (Oct 29, 2023):

It looks like it is curling the frontend, not the backend endpoint - which is why this is occurring. The frontend should be routing all requests to HTTP://localhost:3001/api.

By default, if the frontend/.env file is missing it will fallback to /api which would then resolve all backend calls to http://localhost:3000/api/....

The yarn setup command would have handled this on localhost as yarn setup:envs calls cp -n ./frontend/.env.example ./frontend/.env

So in summary, to solve your issue
cp -n ./frontend/.env.example ./frontend/.env and then rebuild frontend and it will then talk to the backend via the right URL on localhost.

@timothycarambat commented on GitHub (Oct 29, 2023): It looks like it is curling the frontend, not the backend endpoint - which is why this is occurring. The frontend should be routing all requests to HTTP://localhost:3001/api. By default, if the `frontend/.env` file is missing it will fallback to `/api` which would then resolve all backend calls to `http://localhost:3000/api/...`. The `yarn setup` command would have handled this on localhost as `yarn setup:envs` calls `cp -n ./frontend/.env.example ./frontend/.env` So in summary, to solve your issue `cp -n ./frontend/.env.example ./frontend/.env` and then rebuild frontend and it will then talk to the backend via the right URL on localhost.
yindo changed title from Localhost remains in the same state(not responding) to [GH-ISSUE #306] Localhost remains in the same state(not responding) 2026-06-05 14:33:54 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#178