fix(parallels): send guest prep scripts over stdin - #2431
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: blocked before merge. Reviewed September 21, 2026, 5:39 AM ET / 09:39 UTC (Revision 2). ClawSweeper reviewWhat this changesThe PR sends Parallels guest preparation and SSH-key installation scripts through stdin, isolates child-command input, and adds regression tests and documentation. Merge readiness⛔ Blocked before merge - 3 items remain The repair remains necessary and has convincing native macOS evidence. No introduced correctness defect was found; the previously identified Linux compatibility coverage decision remains unresolved. Priority: P2 Review scores
Verification
How this fits togetherCrabbox prepares cloned Parallels VMs before running workloads over SSH. Generated preparation scripts travel through local Parallels tooling or SSH to a remote host, and their results determine whether provisioning proceeds or cleans up the clone. flowchart TD
A[Clone and lease settings] --> B[Generate preparation scripts]
B --> C{Host location}
C --> D[Local Parallels command]
C --> E[SSH to remote host]
D --> F[Guest shell reads stdin]
E --> F
F --> G{Preparation succeeds}
G --> H[SSH readiness or clone cleanup]
Decision needed
Why: The implementation restores intended failure checks, but accepting the remaining platform compatibility uncertainty requires maintainer judgment. Before merge
Agent review detailsSecurityNone. Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Retain shared stdin delivery and explicit best-effort exceptions, with Linux fresh-template and upgrade compatibility demonstrated or its bounded coverage limit explicitly accepted. Do we have a high-confidence way to reproduce the issue? Yes: main retains the faulty argv transport, and the supplied native control demonstrates swallowed shell failures. This review inspected the path without independently executing it. Is this the best way to solve the issue? Yes: stdin delivery follows the existing SSH bootstrap pattern and avoids guest-side argv reconstruction; child-input isolation addresses the resulting consumption hazard. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 05415421726c. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
Document the behavior restored by #2401 and credit its contributor in the Unreleased changelog.
f51768e to
74d0015
Compare
Parallels guest preparation and SSH-key installation now stream their POSIX scripts to
/bin/sh -sover stdin.prlctl execflattens argv, so the previous script argument could silently loseset -eu. Both local and SSH-to-host routes preserve stdin, host identity, PATH, and environment filtering; child commands cannot consume the remaining script input.Fixes #2396.
This supersedes #2401 only because of its merge conflict after #2415 landed. The rebase preserves both the landed caller-context IP-discovery diagnostics and the original stdin fix. The Go changes applied unchanged; the changelog conflict was resolved by retaining both sides. The contributor's branch was not force-pushed. The coordinator will close the original PR as superseded when this PR merges.
Credit to @saariuslystoned for the implementation and regression tests. The implementation commit preserves
Co-authored-by: Bobby Bones <saariuscrypto@gmail.com>, and the maintainer changelog thanks the contributor. No configuration or credential changes are required.Validation on rebased head
f51768e47b60f8315ca50e6cabfecc3e1837416c:gofmt -l $(git ls-files '*.go'): clean.GOTOOLCHAIN=go1.26.5 GOFLAGS='-mod=readonly -trimpath -p=2' GOMAXPROCS=4 go vet ./...: passed.GOTOOLCHAIN=go1.26.5 GOFLAGS='-mod=readonly -trimpath -p=2' GOMAXPROCS=4 go test -race -count=1 -timeout=15m ./internal/cli/ -run 'Parallels': passed, 7.617 seconds; includes the caller-context diagnostics and stdin regression coverage.Prior full gate on pre-rebase head
aea9efeb512674273fc3dbc13c7d28ab73fc689e, supplied by the coordinator: Crabbox AWSc7a.48xlarge, Go 1.26.5; gofmt OK, go vet OK, build OK, fullgo test -race -count=1 ./...withGO-TEST-RC=0, command-docs OK, docs-links OK. The origin/main baseline was green on the same setup. The coordinator will re-run the full gate on the rebased head before landing. This lane did not independently run a live Parallels guest proof.