Repository source: docs/plans/v3_status_command/v3_status_command_step4_implementation_summary.md
v3 Status Command — Step 4 Implementation Summary
Stage 1 - Shared status snapshot
Changes:
Added
OperatorStatusCollectorfor read-model health, shared-lock, queue-count, and read-model rebuild-task state.Routed
/api/read_model_statusand Tools → System State through the shared collector.Added read-only task-store inspection and prevented lock checks from creating an absent lock file.
Verification:
./v3 test OperatorStatusCollectorTest TaskQueueStoreTest LocalAppSmokeTest::testApplicationRendersTextApisAndRss LocalAppSmokeTest::testReadModelStatusReportsLockedWhenExecutionLockIsHeld— 12 passed.
Notes:
A held lock remains general protected activity; it is not reported as proof of a manual rebuild.
Stage 2 - ./v3 status command
Changes:
Added the read-only
./v3 statusdispatcher command with repository, read-model, queue, rebuild-task, and next-action output.Added explicit repository, read-model database, and queue database path overrides plus help and unknown-option handling.
Added dispatcher-level tests for unavailable state, queued/running rebuilds, and the CLI error contract.
Verification:
php -l scripts/status.php./v3 test StatusCommandTest OperatorStatusCollectorTest TaskQueueCommandTest::testTaskQueueUnknownOptionsShowUsageWithoutAPhpStackTrace— 8 passed../v3 status --helpprinted usage;./v3 status --unknownprinted a concise error and usage with exit code 1.
Notes:
Degraded operational state is reported in normal command output; only invocation errors return a nonzero exit code.
Stage 3 - Documentation and regression coverage
Changes:
Added
./v3 statusreference documentation and updated the operator recovery runbook to make it the primary local status surface.Documented the distinction between a queued-worker rebuild state and a general shared lock.
Added regression coverage for a missing commits capability, preserving the existing stale-status API semantics.
Verification:
./v3 test OperatorStatusCollectorTest StatusCommandTest LocalAppSmokeTest::testApplicationRendersTextApisAndRss LocalAppSmokeTest::testReadModelStatusReportsLockedWhenExecutionLockIsHeld— 10 passed../v3 test— 569 passed; 6 long-standing failures reported by test history in unrelated activity/compose coverage.
Notes:
The command intentionally cannot identify a manual rebuild solely from the lock; the deferred lifecycle-status work remains tracked in
todo.txt.