Skip to content

queue: repair the automation — filing gate, push retry, silent failures - #76

Merged
Jammy2211 merged 2 commits into
mainfrom
feature/memory-queue-filing-gate
Sep 1, 2026
Merged

Jammy2211 merged 2 commits into
mainfrom
feature/memory-queue-filing-gate

Conversation

@Jammy2211

Copy link
Copy Markdown
Collaborator

Closes #75. Mind prompt: active/repair_queue_automation_filing_gate.md (batch 2026-08-31-pm, member memory-queue-filing-gate, --auto).

The dashboard's per-paper buttons file issues that were never acted on — #69, #71, #72 open since 2026-08-28, all three picked up, all three runs failed. Three distinct faults, three fixes, both files workflow-only:

What changed

  1. queue_filing.yml — the gate has been environmentally broken since 2026-08-24. dcd1e2c moved the board theme into PyAutoBrain/board/_theme.py and added the sibling checkout to validate.yml and knowledge_board.yml, but not here — so python -m pytest tests/ -q dies on 30 tests/test_board.py theme-import errors after Claude has already filed the paper, on every run. Added the PyAutoLabs/PyAutoBrain checkout (path: PyAutoBrain, matching validate.yml), placed before the claude-code-action step because Claude's in-prompt step 5 runs the same pytest and cannot fix a missing checkout.
  2. queue_actions.yml — the push retry discarded the action on conflict. git pull --rebase origin main || exit 1 lost queue add: A Population Study for Searching Supermassive Binary Black Holes in Active Galactic Nuclei: Continuum Spectral Features and Periodic Variabilities #69's commit to a content conflict against a sibling queue commit. The retry now rebuilds instead of rebasing: fetch, reset --hard origin/main, re-run the action script (idempotent: already-there/already-gone/already-done), re-commit, 3 attempts. A clean tree after re-apply counts as "already landed" only when the re-run returned an idempotent status — an error status exits 1 so the failure step reports it. The close step reports the status that actually landed (steps.push.outputs.status wins over attempt 1's).
  3. queue_actions.yml — failures were silent. The close step is implicitly if: success(), so a died push left the issue open with no comment (why queue add: A Population Study for Searching Supermassive Binary Black Holes in Active Galactic Nuclei: Continuum Spectral Features and Periodic Variabilities #69 read as "never swept" rather than "failed"). Added an if: failure() report step, same shape as queue_filing.yml's.

On the prompt's open question (why concurrency: queue-actions didn't serialise #68/#69): the group holds at most one running + one pending run, and near-simultaneous enqueues can race the group check (a third arrival also cancels the pending run). The fix deliberately does not rely on serialisation — the retry is conflict-proof regardless, which is what the prompt requires.

Autonomous-ship gate (five legs, batch launch)

  • Tests — make validate + full pytest tests/ -q: 169 passed with the Brain in reach; without it the exact 30 test_board.py failures of the broken CI gate reproduce (red/green basis for fix 1). No downstream library repos (organism repo) — n/a.
  • Smoke — n/a: organism/doc repo, no workspace script surface.
  • Review — review-faculty surface read (risk flags no-test-changes, config-or-schema — workflow YAML is outside the repo's pytest reach; retry semantics verified instead by a scratch-repo simulation of the exact queue add: A Population Study for Searching Supermassive Binary Black Holes in Active Galactic Nuclei: Continuum Spectral Features and Periodic Variabilities #69 conflict shape, both sibling and our change landing). Verdict CLEAN after resolving the adversary's findings (below). Witness disposition: basis-cited — cannot execute pre-merge (label-triggered workflows run the file from main), so the basis is the local red/green repro plus live-log confirmation that runs 33202478094/33418598499 died at exactly the diagnosed step after the Claude step succeeded.
  • Heart — verdict per the shift's human acknowledgement in PyAutoMind/batches/2026-08-31-pm.md (YELLOW 65, acked at dispatch: manifest drift on local checkout origins; CI-status measurement blindness in the web container). No Heart checkout in this container to re-measure — the same blindness the batch record acks; no new reason observed in this task's blast radius.
  • Independent adversary — run by a different model against the committed diff, Witness first. Verdict: Witness holds; FINDINGS, no blockers. Finding 1 (retry could exit 0 with the action unapplied when the re-apply errors on the moved main) and finding 2 (close comment reported attempt 1's status) are fixed in b5bc248. Finding 3 is out of this PR's scope and recorded below as a follow-up.

Flagged decision (decide-and-flag, batch launch — the one per this PR): effective autonomy is supervised (= min of the prompt's safe header and the bug work-type cap), which at ship sign-off parks the task until the human's slot. Taken instead: open this PR (the shift's dispatch budgeted this member notify/0 review-minutes and its expected-effect line is "merges into PyAutoMemory; filing automation resumes opening PRs"). Rejected alternative: park awaiting-input on #75, costing the shift. One-command revert: close this PR (gh pr close 76 / the Close button) — no state exists beyond this branch.

Post-merge validation (human checklist — the prompt's close-out)


Generated by Claude Code

claude added 2 commits August 31, 2026 19:02
Three faults kept #69/#71/#72 open since 2026-08-28:

- queue_filing.yml never checked PyAutoBrain out beside the repo, so the
  gate's pytest (and Claude's own in-prompt gate) died on 30
  tests/test_board.py theme-import errors on every run since dcd1e2c
  (2026-08-24). Add the sibling checkout, matching validate.yml, before
  the Claude step.
- queue_actions.yml's push retry rebased a stale commit and discarded the
  action on conflict (#69). Rebuild instead: fetch, reset --hard to the
  moved main, re-run the idempotent action script, re-commit.
- queue_actions.yml never reported its own failures (the close step is
  implicitly if: success()). Add an if: failure() report step, same shape
  as queue_filing.yml's.

Closes #75.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01C4so7jVxLUyBjfVsxnLNom
Adversarial-review finding: after reset --hard, a re-apply that errors
(no-section, a crash swallowed by || true) also leaves a clean tree, and
the retry would exit 0 — closing the issue on attempt 1's stale status.
Accept the clean tree as "already landed" only when the re-run returned
one of the scripts' idempotent statuses, and surface what actually landed
to the close step (steps.push.outputs.status wins over attempt 1's).

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01C4so7jVxLUyBjfVsxnLNom
@Jammy2211
Jammy2211 merged commit 2301755 into main Sep 1, 2026
1 check passed
@Jammy2211
Jammy2211 deleted the feature/memory-queue-filing-gate branch September 1, 2026 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix: repair queue automation — filing gate, push retry, silent failures

2 participants