You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug(test): the extension suite loads a real launchd job on every Mac — a fleet-scripts test reaches /bin/launchctl and leaves a respawning 'ssh hq' agent #1783
Problem — The extension fast suite loads a real launchd job on every Mac it runs on. A test in the fleet-scripts projection suite runs the fleet installer in install mode on Darwin with no stub for launchctl. The installer then calls the real /bin/launchctl and loads a fabricated co.harmoniqs.amico-tunnel agent from the test's temp dir: KeepAlive + RunAtLoad, running /usr/bin/ssh hq. Its temp dir is deleted afterwards, but the job stays loaded and launchd keeps respawning it. Observed on JJ's laptop 2026-10-12: launchctl print gui/<uid>/co.harmoniqs.amico-tunnel → path /private/var/folders/…/T/fleet-scripts-Un0vh2/Library/LaunchAgents/co.harmoniqs.amico-tunnel.plist, program /usr/bin/ssh hq, runs = 80, last exit 255, state "spawn scheduled". The real amico-tunnel label belongs to the fleet's hub link, so a stray job under that label can also mislead the healthcheck and the installer's own --check. Approach — Tests must never reach the real service manager: the installer gets a seam for the launchctl binary and the LaunchAgents dir, and the suite runs every installer invocation against recording stubs with a PATH backstop the tests assert is never hit. Fixed on #1775's branch (commit edfa917), landing with the #1770 integration PR (#1781).
Acceptance Criteria
No extension test invokes the real launchctl or systemctl — a PATH backstop records any call that bypasses the seam, and a test asserts the backstop was never reached.
After a full extension fast-suite run on macOS, launchctl list shows no job whose plist lives under a temp directory.
Notes
One-time cleanup on any Mac that ran the extension suite before the fix lands — check, then remove the stray job: launchctl print gui/$(id -u)/co.harmoniqs.amico-tunnel | grep path — if the path is under /private/var/folders/…/T/, run launchctl bootout gui/$(id -u)/co.harmoniqs.amico-tunnel. Do NOT boot it out if the path is ~/Library/LaunchAgents/co.harmoniqs.amico-tunnel.plist — that is a real hub link on a fleet client.
Root cause fixed on the #1770 integration branch (3a6be6a, PR #1781): installer seam + recording launchctl stub + an asserted PATH backstop. Verified by the director: the integrated suite at 8965094 no longer re-registers the stray job (its plist path stayed fixed across a full run). Note: running the full suite on any branch WITHOUT that fix (including old main) still re-loads it from a new temp dir — observed once during this campaign. The one-time cleanup in the body is still needed on each Mac that ran the suite. Leaving this open until #1781 merges to main.
Activity
Merge #1775: installer-managed per-peer SSH forwards with standard ke…
jeonghun-jj-lee commentedon Oct 13, 2026
Root cause fixed on the #1770 integration branch (3a6be6a, PR #1781): installer seam + recording launchctl stub + an asserted PATH backstop. Verified by the director: the integrated suite at 8965094 no longer re-registers the stray job (its plist path stayed fixed across a full run). Note: running the full suite on any branch WITHOUT that fix (including old
main) still re-loads it from a new temp dir — observed once during this campaign. The one-time cleanup in the body is still needed on each Mac that ran the suite. Leaving this open until #1781 merges to main.