Skip to content

fix(linux): fail early without a display and clarify virtual display setup - #241

Open
qinghuanandejiangshi wants to merge 1 commit into
egoist:mainfrom
qinghuanandejiangshi:feature/20260917-linux-startup
Open

qinghuanandejiangshi wants to merge 1 commit into
egoist:mainfrom
qinghuanandejiangshi:feature/20260917-linux-startup

Conversation

@qinghuanandejiangshi

Copy link
Copy Markdown

Problem and solution

On Linux, launching the desktop without a display starts its daemon and then waits indefinitely in GPUI's headless backend. Check gpui::guess_compositor() before calling waku::run() and exit with a graphical-session diagnostic instead. This also handles empty display variables and ZED_HEADLESS; the standalone daemon is unchanged.

The Linux guide now explains the window-manager requirement for bare Xvfb, gives a working Openbox example, and sets both Vulkan driver override spellings for older loaders.

Checks

  • Native Linux arm64 executable, Debian 13 container: both integration tests pass (six environment cases). Against the official 0.1.19 executable, the headless regression fails and the configured-display control passes.
  • Actual old executable without a display: still running after 5 seconds, with a daemon child. Fixed executable: exit 1 in 7 ms with the display diagnostic.
  • Actual X11 windows: old executable on bare Xvfb is black; adding Openbox renders the UI. The fixed debug executable also renders with the documented xvfb-run command. The visual probe uses the official 0.1.19 companion daemon and isolated state, without model calls.
  • macOS: formatting, cargo check, full cargo test (975 passed, 39 ignored), protocol consistency, client typecheck and 23 client tests pass. Used gpui_platform/runtime_shaders and the 26.5 SDK because the optional Metal compiler is unavailable locally.
  • Checked the old Vulkan 1.3.204 loader source and the current Khronos driver-override documentation.

Limitations and follow-up

No real Wayland compositor was exercised; Wayland configuration is covered by the startup pass-through test. The Linux test build uses Rust 1.98.0 with unoptimized dependencies and debug assertions enabled. Ubuntu 22.04 itself was not run; its documented loader version was checked in upstream source. This does not make bare Xvfb render without a window manager or repair missing graphics drivers.

Related issue

Fixes #236. Fixes #238.

AI disclosure

OpenAI Codex assisted with investigation, implementation, tests, validation and this PR description. The account owner authorized AI-written submission text. The change and recorded results were reviewed; the description is not claimed to be human-written.

Checklist

  • The complete change and validation results have been reviewed.
  • I wrote this description myself, without LLM-generated text, and will write PR comments myself.
  • All AI usage is disclosed, including the tools and extent of involvement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant