feat: operationalise project bus for Sandbox
This commit is contained in:
@@ -0,0 +1,77 @@
|
||||
# WP-PA-002 Implementation Evidence
|
||||
|
||||
Baseline: `a2229bc26902e79d63a368e8ab002ebefd4f0863`
|
||||
Implementer: Codex (`IMPLEMENTER`)
|
||||
Date: 2026-07-30
|
||||
|
||||
## Scope delivered
|
||||
|
||||
- repeatable Sandbox project and actor bootstrap manifest;
|
||||
- operational CLI for authenticated bootstrap and consistent SQLite backup;
|
||||
- hardened loopback-only Compose profile and external secret template;
|
||||
- activation, rollback, credential rotation, cursor recovery, backup and
|
||||
restore runbook;
|
||||
- regression coverage against the real migrated database schema;
|
||||
- independent-review brief for Claude Code.
|
||||
|
||||
## Local verification
|
||||
|
||||
Python: `3.12.13`
|
||||
|
||||
```text
|
||||
PYTHONPATH=src python3.12 -m unittest discover -s tests -v
|
||||
Ran 24 tests in 7.315s
|
||||
OK
|
||||
|
||||
PIP_NO_CACHE_DIR=1 <clean-venv>/bin/pip install --no-deps .
|
||||
<clean-venv>/bin/python -m unittest discover -s tests -v
|
||||
Ran 24 tests in 6.201s
|
||||
OK
|
||||
|
||||
python3.12 -m compileall -q src tests
|
||||
git diff --check
|
||||
```
|
||||
|
||||
Both final commands completed without output or error.
|
||||
|
||||
The operational exercise used a fresh migrated database and verified:
|
||||
|
||||
- first bootstrap creates the project and five distinct formal actors;
|
||||
- replay with the same manifest and stable idempotency keys creates no
|
||||
additional events;
|
||||
- PO, PM, PA, Codex and Claude identities authenticate independently and can
|
||||
read the roster, synchronize events and query role-filtered pending actions;
|
||||
- online backup completes with `PRAGMA integrity_check = ok`;
|
||||
- the restored database has the same maximum `event_log.cursor` as its source.
|
||||
|
||||
The backup exercise initially exposed an incorrect `events(sequence)` query.
|
||||
The implementation now queries the actual migrated schema,
|
||||
`event_log(cursor)`, and
|
||||
`test_backup_is_consistent_and_integrity_checked` prevents regression.
|
||||
|
||||
## Container verification handoff
|
||||
|
||||
No Docker or Podman runtime is installed in the implementer's Work
|
||||
environment. The implementer therefore did not claim container-build or
|
||||
runtime evidence. The independent reviewer must build the exact review commit
|
||||
in a Docker-capable environment and verify:
|
||||
|
||||
- successful image and Compose build;
|
||||
- healthy service;
|
||||
- runtime UID `65532`;
|
||||
- read-only root filesystem, dropped capabilities and
|
||||
`no-new-privileges`;
|
||||
- loopback-only published port;
|
||||
- persistent database volume.
|
||||
|
||||
This is an explicit review task in `WP-PA-002-REVIEW-BRIEF.md`, not a waived
|
||||
acceptance criterion.
|
||||
|
||||
## Secret handling and authority
|
||||
|
||||
No populated environment file or actor credential is part of the worktree.
|
||||
`deploy/project-bus.env.example` contains placeholders only. The runbook keeps
|
||||
SG, PTO and existing project threads authoritative until an independent
|
||||
`APPROVE` and PM `ACCEPT`. No endpoint, VM, purchase or internet-facing
|
||||
deployment was created by this work package.
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
# Independent Review Brief — WP-PA-002
|
||||
|
||||
Reviewer: Claude Code (`REVIEWER`)
|
||||
Implementer: Codex (`IMPLEMENTER`)
|
||||
|
||||
Review only the exact commit supplied by the PA. Do not change, commit or push
|
||||
implementation code. Verify that the commit descends from accepted WP-PA-001
|
||||
commit `a2229bc26902e79d63a368e8ab002ebefd4f0863`.
|
||||
|
||||
## Required review
|
||||
|
||||
1. Match every acceptance criterion in `work-packages/WP-PA-002.md` to
|
||||
implementation and independent evidence.
|
||||
2. Build and run the packaged application under Python 3.12.
|
||||
3. Build and run the container, confirm its health check and non-root identity.
|
||||
4. Bootstrap a fresh database twice and prove replay creates no extra events.
|
||||
5. Authenticate separately as PO, PM, PA, Codex and Claude; verify the roster,
|
||||
event sync and pending-actions reads.
|
||||
6. Create a live backup, restore it in isolation, run integrity checks and
|
||||
compare event cursors.
|
||||
7. Search Git history and the reviewed tree for committed credentials.
|
||||
8. Adversarially verify that bootstrap/operations tooling cannot weaken the
|
||||
governance invariants accepted in WP-PA-001.
|
||||
9. Verify the runbook preserves SG/PTO/project-thread authority until the
|
||||
independent `APPROVE` and PM `ACCEPT` activation gate.
|
||||
10. Check that no deployment is described as production-ready beyond the
|
||||
constraints in `docs/PRODUCTION_PROFILE.md`.
|
||||
|
||||
Write `REVIEW-REPORT-WP-PA-002.md` with exactly one verdict:
|
||||
`APPROVE`, `CHANGES_REQUESTED`, or `REJECT`. Include exact commit SHA,
|
||||
environment, commands, results, findings with severity, residual risks, and a
|
||||
machine-readable summary.
|
||||
Reference in New Issue
Block a user