[PR #1902] [MERGED] horizon-server: lock test no longer flakes on a spawned child's descriptor #3851

Closed
opened 2026-11-03 04:12:47 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

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

Base: main ← Head: fix/supervisor-lock-test-race


📝 Commits (1)

  • 4513af8 horizon-server: the lock test waits for a fork-held descriptor to close

📊 Changes

1 file changed (+11 additions, -1 deletions)

View changed files

📝 crates/horizon-server/src/supervisor.rs (+11 -1)

📄 Description

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

supervisor::tests::one_supervisor_per_folder failed on CI twice today (#1833, #1895: "a server is already running" when relocking right after the first lock was dropped). Other tests in the same binary spawn processes (tar, the engine), and between fork and exec the child holds a copy of every open descriptor, the lock's included, so the flock is briefly still held. The test now retries the relock for up to 1 s.

Test only, no player-visible change. cargo test -p horizon-server --bin horizon-server supervisor: 7 pass.

🤖 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/1902 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/25/2026 **Status:** ✅ Merged **Merged:** 10/25/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/supervisor-lock-test-race` --- ### 📝 Commits (1) - [`4513af8`](https://github.com/horizon-rust/horizon/commit/4513af89954872409e1f02909633789c6293a5a9) horizon-server: the lock test waits for a fork-held descriptor to close ### 📊 Changes **1 file changed** (+11 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-server/src/supervisor.rs` (+11 -1) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. `supervisor::tests::one_supervisor_per_folder` failed on CI twice today (#1833, #1895: "a server is already running" when relocking right after the first lock was dropped). Other tests in the same binary spawn processes (`tar`, the engine), and between fork and exec the child holds a copy of every open descriptor, the lock's included, so the flock is briefly still held. The test now retries the relock for up to 1 s. Test only, no player-visible change. `cargo test -p horizon-server --bin horizon-server supervisor`: 7 pass. 🤖 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 04:12:47 +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#3851
No description provided.