A card's workspace no longer leaves its app running

The same run against the code before and after the change, on Windows: a card whose worktree still has its app running lands, and Obeya removes the worktree.

The run

  1. A card's worktree; the repository's stop command is node .obeya/app.mjs stop, but the card's branch is older than that script.
  2. The app runs from the worktree: a server started detached in server/, holding a file open there, with no process IDs written anywhere.
  3. The card's app is stopped (as while it waits for the owner), then the card lands and its worktree is removed.

Before

error
Stopping the app is an error on the card
Cannot find module …\.obeya\app.mjs: the branch has no such script, so there was nothing to stop.
runs on
The app keeps running
The stop command cannot find it; nothing else looks.
half gone
The worktree is only half removed
git worktree remove fails on the file the app holds: its git link is gone, server/ stays on disk, and no card owns it any more.

After

quiet
No error on the card
A stop command whose script the workspace lacks does not run: nothing of it can run there.
ended
The app is ended before the folder goes
Obeya ends every process still running from the folder: program, working directory or command line inside it.
removed
The worktree is gone entirely
Nothing holds its files any more, so the removal finishes.

This runs before every workspace folder Obeya deletes: a landed or discarded card's worktree, a follow-up's temporary worktree, and a clone that leaves the pool. The repository's own stop command still runs first; Obeya's sweep catches what it missed. Obeya itself and the processes it runs are never ended. Built for Windows, Linux and macOS and for remote machines; this run is on Windows.