You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
terminal web UI not working - issue with socket connection #169
First off: I'm really glad you're building this product. I love it and I really want to work with it!
I tried setting up the perry agent both locally in my macbook pro M3 and In my ubuntu-server based homelab, and I'm running into the same issue in both:
When trying to use the web UI to access my terminal, or create an agent session, I see an error in the console indicating that the websocket connection was refused.
I launched OpenCode on this repo to ask about it, and it hinted me the following:
Root Cause: Authentication
The WebSocket connection is failing because browsers cannot send Authorization headers with WebSocket connections. Here's what happens:
1. The web UI stores the auth token in localStorage and uses it for API calls (via fetch)
2. When opening a WebSocket, the browser cannot include the Authorization: Bearer <token> header
3. Your server has config.auth.token set (auth is enabled)
4. The server rejects the WebSocket upgrade request with 401 Unauthorized
5. This causes the 1006 (abnormal closure) error
Oh yeah you're very right. Auth was added after i had terminal working, and I end up not using the terminal that much so it fell through the cracks. Thanks for the report, ill have a fix soon
Activity
gricha commentedon Feb 16, 2026
Oh yeah you're very right. Auth was added after i had terminal working, and I end up not using the terminal that much so it fell through the cracks. Thanks for the report, ill have a fix soon
gricha commentedon Feb 16, 2026
This should be fixed with #170
on v.0.5.1, lmk if you are still having some issues and thank you!