Skip to content

Web & Desktop home UIs render no projects/sessions against a headless server (v1.18.19) although GET /project returns the registered git project #44216

Description

@leolau

Environment

  • opencode web v1.18.19 headless on Ubuntu 24.04 (systemd), --hostname 127.0.0.1 --port 4096, WorkingDirectory set to a git repository (/opt/data/aicoding/repos/ai-prentice-4-all).
  • Clients tested: web UI via HTTPS reverse proxy (Chrome, normal + private windows), Desktop app 1.18.x (macOS arm64) connected via defaultServerUrl (tunnel), TUI via opencode attach.

Expected

Home UI lists the server's project (the git repo) and its sessions; "+"/Add project usable.

Actual

  • Web home shows Nothing here yet / Create a session to get started; Add project greyed; no project nodes (also with ?directory=<repo> in the URL and in a clean private window).
  • Desktop shows the server as connected (green dot, Default Server) but lists no sessions/projects; its Add project opens the local OS file picker (useless for a remote server).
  • TUI (opencode attach) works fine and lists sessions — so the server itself is healthy.

Evidence (server side is correct)

GET /project returns:

[{"id":"global","worktree":"/"},{"id":"76860fc1…","worktree":"/opt/data/aicoding/repos/ai-prentice-4-all","vcs":"git","sandboxes":[]}]

GET /session?directory=<repo> returns sessions with that projectID. GET /global/health = {"healthy":true}.

Tried

  • POST /session?directory=<repo> (registers project correctly; UI still empty).
  • POST /experimental/workspace {"type":"worktree"}WorkspaceCreateError: Timed out waiting for global event (and, before the project existed, Worktrees are only supported for git projects).
  • Setting server cwd to the git repo (project then auto-registers; UI still empty).
  • Private/incognito windows; hard reloads.

Impact

Headless deployments (the documented opencode serve/opencode web use-case) have no usable web/desktop home; only the TUI works. Related: #7790, #7371.

Suggestion

Home should render GET /project results regardless of workspace layer; web needs a server-side directory picker instead of the OS picker; workspace creation should not hang (Timed out waiting for global event).

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions