[PR #2940] [MERGED] Harnesses run offscreen on a Linux without vscreen #4696

Closed
opened 2026-11-03 05:07:16 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/2940
Author: @ASOwnerYT
Created: 10/27/2026
Status: ✅ Merged
Merged: 10/28/2026
Merged by: @rdbtCVS

Base: main ← Head: tools/harness-no-vscreen


📝 Commits (1)

  • c309d33 Harnesses run offscreen on a Linux without vscreen

📊 Changes

3 files changed (+12 additions, -8 deletions)

View changed files

📝 tools/lan_e2e.py (+7 -5)
📝 tools/test_save_roundtrip_parity.py (+2 -1)
📝 tools/test_world_reopen_parity.py (+3 -2)

📄 Description

🤖 Opened by asowneryt's AI agent (Claude Code), not by asowneryt himself.

What and why

On a Linux machine without vscreen (the headless compositor the harnesses expect), seven harnesses could not run:

  • save_roundtrip, world_reopen and spawn_loot call vscreen up / vscreen env directly and stop on FileNotFoundError: 'vscreen'.
  • lan_e2e (and the harnesses built on it: remote_fireball, remote_fireworks, server_player_sculk, ...) falls back to the real desktop (agent_control_e2e.game_env keeps DISPLAY). The games open windows that never get focus and pause. A host paused before its world loads stays at "Connecting to the server..." with 0 chunks until wait-ready 400 gives up. This happens on unmodified upstream/main too.

Now, when vscreen is not on PATH, they run as they already do on macOS: the game renders offscreen (--offscreen). lan_e2e also treats that case as a headless run (the existing HORIZON_E2E_HEADLESS path: --offscreen --no-pause). With vscreen installed, nothing changes. HORIZON_E2E_HEADLESS still forces headless as before.

No game code changes.

Vanilla reference

none (harness tooling).

Checked on a Linux desktop without vscreen (Wayland, DISPLAY=:0), with HORIZON_E2E_HEADLESS unset:

Harness upstream/main this branch
save_roundtrip ❌ FileNotFoundError: 'vscreen' ✅ 94 s
world_reopen ❌ FileNotFoundError: 'vscreen' ✅ 22 s
spawn_loot ❌ FileNotFoundError: 'vscreen' ✅ 27 s
remote_fireball ❌ host never loads (wait-ready 400) ✅ 47 s

remote_fireworks, server_player_sculk and friends_integration failed the same way and passed with HORIZON_E2E_HEADLESS=1 (18–53 s), the mode this branch now picks by itself.

Self-check

pr_ready (tools/pr_ready.py --base upstream/main on cachyos, against upstream/main at f21e09510, 1 min 56 s)

Check Result
Scope ✅ 3 files, +12 −8
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 398 passed (21 s)
rustfmt ➖ no Rust change
clippy ➖ no Rust change
tests ➖ no crate touched
doc tests ➖ no crate touched
content root tests ➖ content root untouched
tokens.css up to date ➖ theme untouched
launcher rustfmt ➖ launcher untouched
launcher clippy ➖ launcher untouched
launcher tests ➖ launcher untouched
Parity ✅ 7 affected, 6 passed (1 min 34 s)
Label skip-release

The 7th affected harness is lan_integration (the whole lan_e2e suite), which pr_ready never selects: it runs nightly or when named.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/2940 **Author:** [@ASOwnerYT](https://github.com/ASOwnerYT) **Created:** 10/27/2026 **Status:** ✅ Merged **Merged:** 10/28/2026 **Merged by:** [@rdbtCVS](https://github.com/rdbtCVS) **Base:** `main` ← **Head:** `tools/harness-no-vscreen` --- ### 📝 Commits (1) - [`c309d33`](https://github.com/horizon-rust/horizon/commit/c309d331ad3c78da74d192227cf8e325322e7127) Harnesses run offscreen on a Linux without vscreen ### 📊 Changes **3 files changed** (+12 additions, -8 deletions) <details> <summary>View changed files</summary> 📝 `tools/lan_e2e.py` (+7 -5) 📝 `tools/test_save_roundtrip_parity.py` (+2 -1) 📝 `tools/test_world_reopen_parity.py` (+3 -2) </details> ### 📄 Description > 🤖 Opened by asowneryt's AI agent (Claude Code), not by asowneryt himself. ## What and why On a Linux machine without `vscreen` (the headless compositor the harnesses expect), seven harnesses could not run: - `save_roundtrip`, `world_reopen` and `spawn_loot` call `vscreen up` / `vscreen env` directly and stop on `FileNotFoundError: 'vscreen'`. - `lan_e2e` (and the harnesses built on it: `remote_fireball`, `remote_fireworks`, `server_player_sculk`, ...) falls back to the real desktop (`agent_control_e2e.game_env` keeps `DISPLAY`). The games open windows that never get focus and pause. A host paused before its world loads stays at "Connecting to the server..." with 0 chunks until `wait-ready 400` gives up. This happens on unmodified `upstream/main` too. Now, when `vscreen` is not on `PATH`, they run as they already do on macOS: the game renders offscreen (`--offscreen`). `lan_e2e` also treats that case as a headless run (the existing `HORIZON_E2E_HEADLESS` path: `--offscreen --no-pause`). With `vscreen` installed, nothing changes. `HORIZON_E2E_HEADLESS` still forces headless as before. No game code changes. ## Vanilla reference none (harness tooling). Checked on a Linux desktop without `vscreen` (Wayland, `DISPLAY=:0`), with `HORIZON_E2E_HEADLESS` unset: | Harness | `upstream/main` | this branch | | --- | --- | --- | | `save_roundtrip` | ❌ `FileNotFoundError: 'vscreen'` | ✅ 94 s | | `world_reopen` | ❌ `FileNotFoundError: 'vscreen'` | ✅ 22 s | | `spawn_loot` | ❌ `FileNotFoundError: 'vscreen'` | ✅ 27 s | | `remote_fireball` | ❌ host never loads (`wait-ready 400`) | ✅ 47 s | `remote_fireworks`, `server_player_sculk` and `friends_integration` failed the same way and passed with `HORIZON_E2E_HEADLESS=1` (18–53 s), the mode this branch now picks by itself. ## Self-check **pr_ready** (`tools/pr_ready.py --base upstream/main` on cachyos, against upstream/main at f21e09510, 1 min 56 s) | Check | Result | | --- | --- | | Scope | ✅ 3 files, +12 −8 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 398 passed (21 s) | | rustfmt | ➖ no Rust change | | clippy | ➖ no Rust change | | tests | ➖ no crate touched | | doc tests | ➖ no crate touched | | content root tests | ➖ content root untouched | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ➖ launcher untouched | | launcher clippy | ➖ launcher untouched | | launcher tests | ➖ launcher untouched | | Parity | ✅ 7 affected, 6 passed (1 min 34 s) | | Label | `skip-release` | The 7th affected harness is `lan_integration` (the whole `lan_e2e` suite), which pr_ready never selects: it runs nightly or when named. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 05:07:16 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#4696
No description provided.