Skip to content

fix: scope holder discovery on windows - #534

Open
petrofahed wants to merge 1 commit into
herdrdev:masterfrom
petrofahed:codex/windows-holder-discovery
Open

petrofahed wants to merge 1 commit into
herdrdev:masterfrom
petrofahed:codex/windows-holder-discovery

Conversation

@petrofahed

Copy link
Copy Markdown

Problem

On one Windows workstation with a busy named-pipe namespace, core 0.1.23 took 209.4 seconds from a fresh launch to a successful hc server status. Startup enumerates the entire named-pipe namespace before it can adopt holders.

Change

Query for the exact legacy holder and the current session’s holder pattern with Win32 file enumeration. Keep the existing name filter and adoption flow. Preserve Unix directory enumeration behind the same platform interface. A Windows regression test exercises absent holders, the legacy name, both observed generation lengths, an unrelated session, and a non-holder suffix.

Windows verification

Tested on Jupiter with Herdr App 0.1.20, the bundled ConPTY files, and a local Windows GNU build of this branch. The desktop was launched in fresh isolated profiles without prestarting core.

Check Observed
Cold start App and core ready in 1.927 s, 0.726 s, and 0.786 s across three runs
Resume App reopened in 1.037 s with the same workspace, tab, pane, and PowerShell PID
Recovery The same holder, shell, and output survived both hc server restart and a forced core stop. The recovered shell executed a fresh command
Concurrent start Two overlapping hc server start calls returned the same core PID
Failed start An invalid pipe path returned a clear error, exit 2, and no running core

cargo fmt --all --check, the Windows holder-discovery regression, the locked build, and both CLI documentation tests passed. The candidate was a local build. A signed-release rerun is pending.

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant