[PR #968] [MERGED] lan_e2e: tidy the hazards box from the host #2950

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

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/968
Author: @ludovic111
Created: 10/19/2026
Status: ✅ Merged
Merged: 10/19/2026
Merged by: @ludovic111

Base: main ← Head: fix/lan-e2e-hazards-tidy


📝 Commits (1)

  • 2e730b9 lan_e2e: tidy the hazards box from the host

📊 Changes

1 file changed (+5 additions, -3 deletions)

View changed files

📝 tools/lan_e2e.py (+5 -3)

📄 Description

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

What

tools/lan_e2e.py's hazards check now tidies the guest's stone box from the host instead of the guest: the three cleanup fills after each hazard (water on the fire, air through the box, the stone floor) are host commands.

Why

Found while checking perf-server-11's PRs with lan_e2e. The last hazard teleports the guest into the void. When the server ticks a little sooner than the harness expects, the guest dies before the cleanup fills, and the LAN server drops every packet from a dead guest except ClientCommand (lan_guest_packet), so the fills never ran. The stone box stayed where the next checks put the players:

  • --server-thread: the guest was teleported into the box for pvp and suffocated, so pvp, hurt, respawn and sleep (and sometimes sign) failed with "the dead screen is open" on the guest;
  • plain: the hurt check's pig was summoned inside the box and suffocated before the host could hit it (IndexError in check_hurt).

The guest logs show it: after Teleported Guest to …, -140, … only the first fill ran (Successfully filled 2 block(s)), and the 36 and 9 block fills are missing. Main had the same race but mostly won it: one of its passing --server-thread runs already skipped the floor fill.

How tested

Mac mini, HORIZON_NO_AUDIO=1, with the other sessions keeping it 80–90 % busy:

  • --server-thread --check hazards --check pvp --check hurt --check respawn --check sleep with perf-server-11's builds (all four of its PRs merged together): 3 passes out of 3 with this change. Without it, builds with those PRs failed pvp, hurt, respawn and sleep in 8 of 10 runs, and a plain run lost the pig once.
  • Full runs, current main + this change, and the same with perf-server-11's PRs: nothing here fails that doesn't fail on main too. On this busy machine both fail some checks, and not always the same ones: swings every time, self and crafting with --server-thread, and now and then sign, effects, hurt, projectiles, portals or growth. Those checks aren't touched here.
  • python3 -m py_compile tools/lan_e2e.py.

Needs Ludovic

Nothing. A question for later, not this PR: Horizon's LAN server ignores a dead guest's chat commands; I haven't checked whether vanilla's ServerGamePacketListenerImpl runs them.

🤖 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/968 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/19/2026 **Status:** ✅ Merged **Merged:** 10/19/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/lan-e2e-hazards-tidy` --- ### 📝 Commits (1) - [`2e730b9`](https://github.com/horizon-rust/horizon/commit/2e730b9213ce6be4b0dded9545a0553b51b987b6) lan_e2e: tidy the hazards box from the host ### 📊 Changes **1 file changed** (+5 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `tools/lan_e2e.py` (+5 -3) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. ## What `tools/lan_e2e.py`'s hazards check now tidies the guest's stone box from the host instead of the guest: the three cleanup fills after each hazard (water on the fire, air through the box, the stone floor) are host commands. ## Why Found while checking perf-server-11's PRs with `lan_e2e`. The last hazard teleports the guest into the void. When the server ticks a little sooner than the harness expects, the guest dies before the cleanup fills, and the LAN server drops every packet from a dead guest except `ClientCommand` (`lan_guest_packet`), so the fills never ran. The stone box stayed where the next checks put the players: - `--server-thread`: the guest was teleported into the box for pvp and suffocated, so pvp, hurt, respawn and sleep (and sometimes sign) failed with "the dead screen is open" on the guest; - plain: the hurt check's pig was summoned inside the box and suffocated before the host could hit it (`IndexError` in `check_hurt`). The guest logs show it: after `Teleported Guest to …, -140, …` only the first fill ran (`Successfully filled 2 block(s)`), and the `36` and `9` block fills are missing. Main had the same race but mostly won it: one of its passing `--server-thread` runs already skipped the floor fill. ## How tested Mac mini, `HORIZON_NO_AUDIO=1`, with the other sessions keeping it 80–90 % busy: - `--server-thread --check hazards --check pvp --check hurt --check respawn --check sleep` with perf-server-11's builds (all four of its PRs merged together): 3 passes out of 3 with this change. Without it, builds with those PRs failed pvp, hurt, respawn and sleep in 8 of 10 runs, and a plain run lost the pig once. - Full runs, current main + this change, and the same with perf-server-11's PRs: nothing here fails that doesn't fail on main too. On this busy machine both fail some checks, and not always the same ones: `swings` every time, `self` and `crafting` with `--server-thread`, and now and then `sign`, `effects`, `hurt`, `projectiles`, `portals` or `growth`. Those checks aren't touched here. - `python3 -m py_compile tools/lan_e2e.py`. ## Needs Ludovic Nothing. A question for later, not this PR: Horizon's LAN server ignores a dead guest's chat commands; I haven't checked whether vanilla's `ServerGamePacketListenerImpl` runs them. 🤖 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-02 16:00:20 +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#2950
No description provided.