Skip to content

test(controller-local): match the ssh stub's readiness commands exactly - #252

Merged
benvinegar merged 1 commit into
masterfrom
claude/ssh-stub-staging-flake
Nov 9, 2026
Merged

benvinegar merged 1 commit into
masterfrom
claude/ssh-stub-staging-flake

Conversation

@benvinegar

Copy link
Copy Markdown
Member

macos-shell failed on master at f9dee59 with one check in test/shell/common/controller-local.sh:

✗ cp …/cpfile nosuch:x: rc=1 boxery: prepare local/nosuch: unexpected staging response

Cause. The test's ssh stub exits 0 with no output for any remote command containing 6080, cloud-init or boxery-provision. vm_copy's staging script includes a random 24-hex-digit id (.boxery-copy-<id>-destination), so roughly one run in 3,000 the id contains 6080. The stub then "succeeds" for a VM that doesn't exist, and copy rightly rejects the empty reply as an unexpected staging response instead of reaching the "no such vm" path. Feeding the stub that call with a 6080 id reproduces it: exit 0 instead of 255. The failure appears once in the last 25 failed CI runs, and it predates the test reorganisation in #245.

Fix. The stub now matches the three commands it actually stands in for, which I logged from a full run: cloud-init status --wait, the noVNC readiness loop (127.0.0.1:6080/vnc.html) and the provisioning check (/var/log/boxery-provision.ok). None of them can appear in a hex id. Deleting the line isn't an option: new --headless and the ls checks after it depend on it.

Checks. npm run lint, npm run typecheck, npm test and npm run test:shell pass locally; controller-local.sh also passes under macOS /bin/bash 3.2, and the stub now exits 255 for the 6080 id.

This PR description was generated by Claude Code using Claude Opus 5.5

The ssh stub answered "exit 0, no output" for any remote command containing 6080, cloud-init or
boxery-provision. A copy's staging script carries a random 24-hex-digit id, so about one run in
3,000 the id contained 6080: the stub then pretended a missing VM had staged the copy, and cp
failed with "unexpected staging response" instead of "no such vm" (seen on master, macos-shell).

The stub now matches the three commands it stands in for: cloud-init status, the noVNC readiness
loop and the provisioning check. None can appear in a hex id.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@benvinegar
benvinegar merged commit ded95a1 into master Nov 9, 2026
10 checks passed
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