anomalyco / anomalyco/opencode

[Desktop] App exits on RDP disconnect (Wayland ozone platform)

Open
#46,319 0 comments 0 reactions 1 assignee View on GitHub

@Brendonovich is already working on this.

Since Aug 31, 2026.

Dominant language
TypeScript
Stars
209k
Forks
27.5k
PR merge metrics
PR metrics pending

Description

Description

Desktop app exits when the RDP session disconnects. Setup: headless Ubuntu box (no physical display), GNOME Wayland, accessed via RDP (gnome-remote-desktop). Disconnect RDP → app is gone; reconnect → must restart it manually. Other Electron apps on the same session (e.g. Hermes) survive the disconnect.

Root cause as far as I can tell: the desktop app's renderer is launched with --ozone-platform=wayland (native Wayland surface). On RDP disconnect, gnome-remote-desktop destroys the virtual display (Meta-0), the Wayland surface becomes invalid, the Chromium renderer crashes, and systemd closes the app scope.

Workaround that works for me: launch with --ozone-platform=x11 (XWayland path) — app survives RDP disconnects.

Plugins

None

OpenCode version

1.18.25

Steps to reproduce

  1. Headless Ubuntu machine, GNOME Wayland, no physical monitor
  2. Connect via RDP (gnome-remote-desktop)
  3. Start OpenCode Desktop
  4. Disconnect the RDP session
  5. Reconnect — the app is gone

Screenshot and/or share link

N/A (no display to screenshot; process just exits)

Operating System

Ubuntu 26.04 LTS, GNOME Wayland, gnome-remote-desktop 50.2-0ubuntu0.1

Terminal

N/A (desktop app)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.