f22c6675028a870db2d64b66647c0d6b8d2c9c71
Closes the TODO item about orphaned/duplicated VNC servers across sidecar restarts. The diagnosis there was correct and outlived the move off x11vnc, because the shape of the bug is in the lifecycle, not the server: the running desktop lives in module state, a sidecar restart forgets it while the process keeps running, and waitForPort accepted ANY listener on 5900 as proof of a healthy start. The next start would then spawn a server that could not bind the port, see the ORPHAN listening, and report success — leaving the platform convinced it had started a desktop the browser was not looking at. Two changes. reclaimPort frees the port before spawning: TERM whatever holds it, KILL after two seconds. waitForPort now also fails when the process we spawned has exited, so a foreign listener cannot be mistaken for our own. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Description
No description provided
42 MiB
Languages
TypeScript
90.9%
Shell
4.7%
JavaScript
4.1%
CSS
0.2%
HTML
0.1%