refactor(move): daemon diagnostics scope into daemon-contracts (#3294)
Merged
TH
2mo ago+14+14+01234567890123456789-12-12-01234567890123456789
Summary
Physical root-pass move for src/daemon-diagnostics-scope.ts under #3294 (part of #3276, ADR 0033). The helper now lives at src/daemon-contracts/daemon-diagnostics-scope.ts, the folder whose daemon-contracts zone #3288 already derived logically for it. topFolder now derives the zone from the folder, so the per-file ROOT_MODULE_ZONES row is deleted in the final commit — folder-derived ownership replaces it, no new registry. Importers (daemon/server/daemon-runtime.ts, daemon-registration-owner.ts) re-point; the test file moves with the source and discovery at the new path is verified via vitest list. Refs #3294 (closes when all three root-pass moves land). Stack order: merge this PR first, then #3299 (stacked on this branch).
Validation
- Head
f6723c435:pnpm check:affected --run— all runnable checks passed. git diff -M90% --stat origin/main...HEAD: source file is a 100% rename; test file one import-line fix; no material content change (rename-only move PR).- Planted-violation proof: with the file moved and the row still present,
root-module-zones.test.tsfails withstale: ['src/daemon-diagnostics-scope.ts']; with the row removed it passes. pnpm check:layeringgreen (full R2/R4/R5/R6/R80/R76/R13 report).- Test discovery at the new path:
vitest list src/daemon-contracts/daemon-diagnostics-scope.test.ts --project unit-corelists its three tests. - Public export surface unchanged: the module is internal (no
package.json#exportsentry, no facade). - Review: Follow-ups bullet now records only this file's move as completed and keeps the runtime pair outstanding (cubic P3s resolved; wrong-PR-number thread answered with issue-vs-PR evidence).