docs(prompts): tooling-canary-workflow-rewrite master prompt for Codex #51
No reviewers
Labels
No labels
W6d-automerge-calibration
agent/claude-code
agent/codex
agent/hermes
agent/iskra
agent/ollama
agent/patchwarden
automerge-candidate
class/security-sensitive
cutover-gate
dependency/blocked
dependency/blocks-others
dependency/cross-repo
dependency/needs-confirmation
domain:agents
domain:ci
domain:docs
domain:forgejo
domain:infra
domain:memory
domain:runtime
domain:signal
domain:ux
flow/architecture
flow/blocked
flow/deployed
flow/done
flow/implementation
flow/intake
flow/maintained
flow/observed
flow/ready
flow/refining
flow/retired
flow/review
iterating
judge/codex-candidate
judge/hermes-candidate
judge/low-confidence
judge/needs-refinement
judge/operator-needed
judge/p0
judge/p1
judge/p2
judge/p3
judge/park
judge/patchwarden-candidate
judge/stale-priority
kind/adr
kind/bug
kind/chore
kind/feature
kind/infra
kind/ops
kind/refactor
kind/research
large-impact
merge/auto
merge/manual
merge/manual-dependency-conflict
merge/manual-failing-tests
merge/manual-merge-conflict
merge/manual-missing-review
merge/manual-operator-preference
merge/manual-red-zone
merge/manual-security-sensitive
merge/manual-unclear-scope
merge/manual-unknown
meta
mode:operator-only
mode:patchwarden-iskra-approved
mode:safe-auto
needs-operator-decision
needs-triage
not-ready
observed/erroring
observed/needs-followup
observed/pending
observed/retire-candidate
observed/unused
observed/used
operator-emotional
owner-attention
phase/02
phase/03
priority:p0
priority:p1
priority:p2
priority:p3
proposed
ready-for-agent
ready-for-operator
recovery
review:claude-reviewed
review:codex-reviewed
review:dziadek-reviewed
review:needs-human
risk/exposure
risk/process
risk/product
risk/runtime
safety:external-write
safety:no-prod-mutation
safety:prod-impact
safety:secret-touch
size/large
size/medium
size/small
size/tiny
size/unknown
source/adr
source/agent-generated
source/manual
source/operator-chat
source/voice-note
status:blocked
status:codex-ready
status:merged:pending-evidence
status:needs-evidence
status:operator-needed
status:parked
tier/full
tier/lite
tier/stacked
tier:0-platform-substrate
tier:1-iskra-value-layer
tier:2-tools-products-modules
type:bug
type:chore
type:docs
type:feat
type:policy
type:research
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
pdurlej/platform!51
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "claude/orders/codex-canary-workflow-rewrite-prompt"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Canary status: missing — fire canary 3+3 manually before merge (the workflow this PR rewrites is what would normally auto-fire)
Summary
Master prompt for Codex to rewrite
.forgejo/workflows/canary-required.ymlfixing PR #44 v2 canary findings (BLOCKER + 4 HIGH) PLUS the live failure on PR #50 (workflow run #34 —collect-diffdied after 4s at exactly the predicted Alpine + checkout incompatibility point).Parallel to PR #50 (smoke.sh rewrite master prompt). Per operator 2026-05-04: "lecimy parallel."
Why now (was this scaffold-deferred?)
ADR 0002 v2 marked the workflow as "Accepted design, NOT operational" with intent to defer rewrite. But operator merged it anyway, and on PR #50 it fired and FAILED at the exact point Oracle predicted in PR #44 v2 canary HIGH finding.
Result: every PR opening now creates a red
canary-requiredcheck. The deferred-rewrite strategy isn't sustainable when the workflow actively fails on every PR. Operator 2026-05-04: "czasy się skończyły leniwe."Canary Context Pack
Product story
ADR 0002 + canary 3+3 enforcement is supposed to be the operator's safety net for non-technical-owner merge decisions. Right now the safety net is: workflow runs, fails predictably, blocks nothing (because branch protection isn't configured per Issue #49) — but creates noise. Rewrite makes it: works correctly, soft-skips honestly when secrets absent, ready to enforce after operator setup tasks.
What changed
prompts/tooling-canary-workflow-rewrite.md(286 lines)Why it changed
Files touched
prompts/tooling-canary-workflow-rewrite.md(new)Relevant context
state/reviews/PR-44-v2/decision_packet.md(BLOCKER + 4 HIGH details)Runtime evidence
From workflow run #34 (PR #50, this morning):
findalways reads 0 because state/reviews/ is gitignoredKnown constraints
codex(not pdurlej, not claude)Explicit out-of-scope
Requested decision
approve_merge after canary 3+3 passes (manual fire — workflow this PR rewrites is what would normally auto-fire); OR operator_override per Rule 2.
Merge blockers
How operator triggers Codex
After this PR merges, in master operator (Codex thread):
Codex executes per prompt; opens workflow rewrite PR as
codex; orchestrator (claude) reports back when PR opens.Can run parallel with smoke.sh rewrite (PR #50) — different files, independent Codex sessions. Two tracks fully concurrent.
Test plan
codexCanary statusline per ADR 0001 Rule 1aPer operator instruction 2026-05-04: stop iterating, ship, let Codex egzekwować with full agency. Append BLOCKER + 4 HIGH findings + 3 MEDIUM + honest orchestrator gaps as concrete specs Codex addresses in implementation. Findings appended (with concrete picks Codex should implement): BLOCKER 1: artifact-passing mechanism — picked: artifact name=pr-diff, files=/tmp/canary/pr.diff + /tmp/canary/pr-files.txt, 7-day retention HIGH 2: iter counter marker — picked: HTML comment <!-- canary-decision-packet:v1 --> at top of decision_packet.md; implement in BOTH workflow Iter step + run_review.py --post-forgejo-comment flag (2-file scope) HIGH 3: TOCTOU iter counter race — picked: Forgejo Actions concurrency group `canary-pr-${PR_NUMBER}`, cancel-in-progress: false. Serializes same-key runs. HIGH 4: credential paths in prompt — fix: workflow rewrite PR refs AGENTS.md §Identity-isolation only, no BW item details HIGH 5: soft-skip exits 0 = misleading green — fix: prefer red failure with explicit warning over false-green; verify Forgejo neutral status support MEDIUM 6: bootstrap bleed (broken workflow fires on rewrite PR) — fix: workflow_dispatch only during rewrite phase MEDIUM 7-9: node:20-alpine verification, path classifier file format, SHA pinning specs Honest orchestrator gaps named (don't know Forgejo concurrency support, don't know neutral status support — Codex verifies + picks). Operator override framing: quality gate shifts from prompt review to artifact review (Codex's actual rewrite PR canary). Authored as claude per identity-isolation. Ships with operator_override per ADR 0001 Rule 2.Canary status: operator_override — per operator decision in chat 2026-05-04.
Iter 1 canary returned BLOCKER defer with 9 substantive findings (BLOCKER artifact-passing spec missing; HIGH iter counter marker undefined; HIGH TOCTOU race on iter counter; HIGH credential-paths in prompt; HIGH soft-skip false-green; plus mediums). All real, all worth Codex addressing.
Operator decision: append findings as concrete specs Codex implements (artifact name =
pr-diff; iter marker =<!-- canary-decision-packet:v1 -->HTML comment in BOTH workflow + run_review.py; TOCTOU = Forgejoconcurrency:group; credentials = ref AGENTS.md only; soft-skip = honest red over false-green; etc.).See commit
0ac7871— context section appended at end ofprompts/tooling-canary-workflow-rewrite.md. Codex reads concrete picks + own honest gaps (don't know Forgejo concurrency exact behavior; verify + pick).Quality gate shifts from prompt review to artifact review (canary on Codex's actual workflow rewrite PR will catch implementation issues). Sustainable.
Ready for merge. Note: this rewrite PR will likely require manual canary fire (workflow this PR rewrites is what would normally auto-fire); Codex will document this in its PR description.