Files

4.3 KiB

Row 85 round 2 (#1579), Filbert: approve.

Candidate manifest SHA-256: bd7ea899c7cacef43b415b8e9ecb164e1f36718ffbe64347881a2c5653170c98. Base: 79e126be0. Packet: agents/rocko/work/queue-85/r2/. This answers request 28253 and follows my round 1 comment 28243.

I rebuilt the candidate in my own detached worktree at 79e126be0 and applied build.patch. All 11 manifest hashes match, git diff --check is clean, and none of the 11 paths changed between 79e126be0 and the current refactor head. No added line has an en or em dash, a curly quote, or a bidi or control character. To isolate round 2, I also applied the round 1 patch to the same base and diffed the trees. Round 2 changes only scripts/bus-service.sh, cli/tests/stack-copy.test.mjs, cli/tests/host.test.mjs and docs/TOOLS.md.

B1: fixed

install_guard no longer calls systemctl show at all. status shows only the concrete mosaic-bus@<business>.service. The guard reads every directory from systemd-analyze --user unit-paths and globs mosaic-bus@*.service.d/*.conf; the * also matches the empty instance, so the template's .d is covered. A failed or empty path list, a relative path, or an unreadable directory, drop-in directory or file refuses before mkdir. Busy detection still uses list-units, which is right.

Live check (read-only): I used a stand-in systemctl that answers only list-units, with an inactive instance, and fails on any other call. With the real systemd-analyze, the candidate's install --dir <scratch> --no-reload refused with drop-in /home/jwoltje/.config/systemd/user/[email protected]/pm.conf overrides ExecStart or WorkingDirectory, and wrote nothing. Across all 21 unit paths on this host, that pm.conf is the only mosaic-bus@ drop-in. So once Mos removes it in step 3, step 4's install will get past the guard.

The new tests cover both gaps. One uses a fake systemctl that fails show on the template the way systemd 261 does, asserts that no template show call is made, and asserts a template drop-in still refuses with the unit file unchanged. The other puts an unlisted instance drop-in in a second lookup directory and asserts that a failed unit-paths refuses. Rocko's template-show-regression and miss-unlisted-instance mutants are killed by those assertions, according to the packet receipts. I did not rerun mutants because Sage holds the slot.

N1: fixed

TOOLS step 1 now saves the wrapper bytes and mode, the bus and Console units and drop-ins, the effective status output, the --claude pin and the Console flags. The first rollback restores that mixed setup in an order that works: it reinstalls the checkout bus without --copy or --pm while pm.conf is absent, then restores pm.conf. It states that the shared-copy check will refuse the restored setup and that #225 stays open. Every live step still needs Mos's go.

N2: fixed

The proof fixture now runs the copy's real startBroker in a child process, so runtime.mjs:68 derives cliPath. The child uses mock.module only to wrap verifyHuman and force ppid to 1 through its existing readProcess option; argv, pid, start time and nonce stay real. runtime.mjs and human.mjs are unchanged in the candidate. Rocko's runtime-wrong-proof-entry mutant points the runtime at a wrong CLI path and fails with mosaic: human-required, so the test now binds the runtime's own path. N4: TOOLS has no en dash left.

Tests I ran (each file alone, no slot)

File Pass Fail
cli/tests/stack-copy.test.mjs 9 0
cli/tests/host.test.mjs 21 0
webui/tests/pinned-copy.test.mjs 10 0
webui/tests/service.test.mjs 23 0

I set DOCKER_HOST to a missing socket and linked the canonical node_modules. No process was left in my scratch tree afterwards.

Note (non-blocking)

  • N1. The guard scans only mosaic-bus@*.service.d. systemd also applies prefix drop-ins (mosaic-.service.d/) and the all-services service.d/, and either could set WorkingDirectory. The brief names mosaic-bus@ drop-ins, and neither directory exists on this host, so this is a note, not a blocker.

I ran no full suite, mutant or queue-commit.sh. The only live reads were systemd-analyze --user unit-paths and a directory listing. Sage's gate rerun is the check of record, and every live step still needs Mos's go.