docs(reports): archive Issue #3 analysis, implementation plan, and multi-agent peer review reports
- Add Rev. 3 technical analysis report from creator-agy-01 - Add implementation plan from planner-reviewer-claude-01 - Add peer review reports across analysis and implementation review loops (Claude, Grok, OpenCode)
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
# Re-adjudication: Issue #3 analysis Rev. 3 (Class B reversal)
|
||||
|
||||
- **Reviewer**: `reviewer-creator-grok-01`
|
||||
- **Job**: `1da8fd5c`
|
||||
- **Target**: `.agents/reports/creator-agy-01/issue-3-analysis.md` (Rev. 3, job `6b391a80`)
|
||||
- **Prior**: `1a4f5236` NOT PASS (mechanism); `9075a39f` PASS on Rev. 2. Rev. 3 retracts Class B as a defect.
|
||||
- **Method**: read `verify_session.py:99-101` and `claude.py::resume_spec`; ran `pytest tests/test_uuid_target.py` myself. Did not take the Class B reversal at face value.
|
||||
|
||||
---
|
||||
|
||||
## Class B — `[ADJUDICATION: SUSTAINED]`
|
||||
|
||||
`1a4f5236` claimed assigned `claude`/`grok` ids fail `verify_session_uuid(..., mode="revalidate")` when no transcript exists. That skipped an early return that is live in source:
|
||||
|
||||
```99:101:.agents/skills/lib_py/verify_session.py
|
||||
if (mode == "revalidate" and row.get("session_id_source") == "assigned"
|
||||
and not row.get("session_id_verified")):
|
||||
return True
|
||||
```
|
||||
|
||||
`stop_session.sh` never writes `session_id_source` / `session_id_verified`, so a 0-turn stop keeps `assigned` + `verified=false`. `find_workspace_uuid` therefore emits the YAML own-key. `resume_spec` for claude uses `--session-id` when `materialized` is false (`claude.py:99-100`).
|
||||
|
||||
Independent run: `pytest tests/test_uuid_target.py` → **13 passed in 114.74s** (includes `test_t8_resume_unmaterialized_assigned_id`). Class B 0-turn resume is **working as designed**. Rev. 3 is right to mark it **NOT A DEFECT**. §4 correctly says do not touch this hatch.
|
||||
|
||||
## Item 1 and Class A — still confirmed
|
||||
|
||||
Unchanged from `9075a39f` / live code:
|
||||
|
||||
- **Item 1:** `nohup`+`disown` at `lib.sh:211-213`; non-interactive `&` keeps the shim PGID; `SIGHUP` handled, `SIGTERM`/`SIGINT` to the group are not. Portable `Popen(..., start_new_session=True)` remains the right later fix.
|
||||
- **Class A:** `agy`/`hermes`/`opencode` own-key stays empty; `resume_session.sh:54-57` hard-exits; create still requires `--role`. Automation recovery gap stands. Scope later work to Class A only.
|
||||
|
||||
## Residual nit
|
||||
|
||||
Rev. 3 says `tests/test_uuid_target.py` is **12/12**. This run collected **13** tests, all passing. Does not change the Class B conclusion.
|
||||
|
||||
No `[ESCALATE: PLANNER]`. Analysis-only; planning can proceed on Item 1 + Class A.
|
||||
|
||||
---
|
||||
|
||||
[VERDICT: PASS]
|
||||
@@ -0,0 +1,65 @@
|
||||
# Cross-review: Issue #3 implementation (daemon detach + Class A resume)
|
||||
|
||||
- **Reviewer**: `reviewer-creator-grok-01`
|
||||
- **Job**: `dccd6220`
|
||||
- **Diff**: `lib.sh` shim bootstrap, `resume_session.sh`, `update_yaml_resumed.sh`, tests (`test_uuid_target.py`, `test_herdr_shim_contract.py`)
|
||||
- **Method**: live code + `pytest` of t8/t14/t15/t16/h26 and full `test_uuid_target.py`. `verify_session.py` has **no** git diff.
|
||||
|
||||
---
|
||||
|
||||
## 1. Daemon spawn (`lib.sh` / `.mam/shim/herdr`)
|
||||
|
||||
Replaces `nohup … & disown` with:
|
||||
|
||||
```bash
|
||||
_mam_server_pid=$(python3 -c '
|
||||
import subprocess, sys
|
||||
p = subprocess.Popen(sys.argv[1:], start_new_session=True, ...)
|
||||
print(p.pid)
|
||||
' "$REAL_HERDR" --session "$_MAM_SESSION" server)
|
||||
```
|
||||
|
||||
- `python3 -c` → `sys.argv[0]=='-c'`, `sys.argv[1:]` is the herdr argv. Correct.
|
||||
- Single-quoted `-c` body, so `$_MAM_SESSION` is expanded by bash as an argument, not inside Python. Correct.
|
||||
- Child is session-leader via `os.setsid`; short-lived Python parent exits; herdr is reparented. PGID no longer follows the shim.
|
||||
- `test_h26` extracts the **shipped** statement and asserts child PGID ≠ shell PGID.
|
||||
|
||||
**Met.** Portable (no macOS `setsid` binary).
|
||||
|
||||
## 2. Class A 0-turn resume
|
||||
|
||||
Empty UUID: `agy|hermes|opencode` → `FRESH_SPAWN=1` + `spawn-spec` (not `resume-spec`). `claude|grok` still `exit 1`. YAML update allows empty `--uuid`, stamps `herdr_session_epoch` / `pending-discovery` / `session_id_verified: false` so reconcile cannot pin a pre-resume transcript.
|
||||
|
||||
Tests: t14 (agy dry-run, no `--conversation`), t15 (claude never-created still RC=1), t16 (live resume bumps epoch).
|
||||
|
||||
**Met.** `--role` handoff is no longer required for Class A 0-turn recovery.
|
||||
|
||||
## 3. Class B hatch — preserved
|
||||
|
||||
`verify_session.py:99-101` unchanged (`git diff` empty). `test_t8_resume_unmaterialized_assigned_id` **passed** in this run.
|
||||
|
||||
## Tests (this reviewer)
|
||||
|
||||
```
|
||||
pytest tests/test_uuid_target.py \
|
||||
tests/test_uuid_target.py::test_t8_… \
|
||||
tests/test_uuid_target.py::test_t14_… \
|
||||
tests/test_uuid_target.py::test_t15_… \
|
||||
tests/test_uuid_target.py::test_t16_… \
|
||||
tests/test_herdr_shim_contract.py::test_h26_…
|
||||
→ 20 passed in 246.19s
|
||||
```
|
||||
|
||||
`bash -n` on `lib.sh`, `resume_session.sh`, `update_yaml_resumed.sh` clean.
|
||||
|
||||
## Residual nits (do not block)
|
||||
|
||||
- Already-running Class A + empty UUID still calls `update_yaml_resumed.sh --uuid ""`, which **re-stamps epoch** without respawning. Rare (resume-when-alive). Prefer skipping the epoch reset on the has-session attach path.
|
||||
- No `MAM_VERSION` bump (still `4.1.2`). Fine if this lands in the same unreleased PATCH; bump to 4.1.3 if 4.1.2 already shipped.
|
||||
- Resume `SKILL.md` still says empty UUID → create. Docs drift only.
|
||||
|
||||
No `[ESCALATE: PLANNER]`.
|
||||
|
||||
---
|
||||
|
||||
[VERDICT: PASS]
|
||||
Reference in New Issue
Block a user