Complete the stale-human-feedback gate contract after PR #1337 #1346

Closed
opened 2026-07-15 07:57:23 +00:00 by coilyco-ops · 4 comments
Member

QA finding from the warded control plane coherence ops sweep on 2026-07-15.

Issue #1275 was closed by replacement PR #1337, but the merged implementation only partially satisfies the issue's explicit decision for headless carry. This is a replacement issue with the same labels because the original P0 coherence-core acceptance was not fully met.

What PR #1337 did land:

  • A shared human_feedback.go helper.
  • Director merge eligibility blocking for newer human comments across linked issue and PR comments.
  • Native PR merge/reopen blocking for simple issue-comment cases.
  • Focused tests for director merge and native PR merge/reopen human-comment blocks.

Remaining gaps against #1275:

  • wardAuthoredComment treats forgeForgejo.gitPushUser() as ward-authored before checking structured markers. The issue explicitly says the default ignored-author list is empty, users may not have bot accounts, and Ward core must not ship local bot assumptions. Automation should be identified by structured body markers by default, not by username.
  • There is no documented or implemented feedback-gate config surface for ignored authors or extensible marker classification.
  • The gate reads issue/PR comments, but the issue required issue comments, PR comments, reviews, and relevant issue/PR body update metadata where available.
  • ward agent pr close is not guarded by prWorkflowHumanInterventionGuard, even though #1275 lists closing an issue/PR-like terminal action as gated. If close is intentionally exempt, the contract needs to say so and explain why.
  • Terminal completion is only instructed in seed text. I did not find code-level enforcement preventing WARD-OUTCOME: done / final WARDED_WORKFLOW completion when newer human feedback exists.
  • Tests cover happy blocking for @coilysiren, but not the no-bot-user invariant where a comment authored by the configured push user without ward markers must still block.

Acceptance:

  • Remove username-based default automation classification from wardAuthoredComment; by default, only structured ward marker-family comments are automation.
  • Add/verify a documented config extension point for ignored authors and/or additional automation markers, with default ignored authors empty.
  • Extend the gate to cover PR reviews and available issue/PR update metadata, or explicitly document unavailable Forgejo API gaps and fail conservatively.
  • Apply the gate to all terminal actions named by #1275, including PR close and terminal done/completion paths, or split any intentionally deferred surface into separate issues before closing this one.
  • Add tests proving a no-bot user flow: a plain human comment from the repo owner or configured push user blocks, while ward marker comments do not.
  • Keep the already-landed merge/reopen protections from PR #1337 intact.

Evidence checked:

  • cmd/ward/human_feedback.go on current main contains strings.EqualFold(..., forgeForgejo.gitPushUser()) in wardAuthoredComment.
  • cmd/ward/agent_pr_workflow.go uses the guard for merge/reopen but not close.
  • cmd/ward/agent_workflow.go updates prompt/seed text about terminal workflow comments, but I did not find a code gate for posting terminal completion.
  • Focused current-main test run passed: go test ./cmd/ward -run 'Human|Feedback|Intervention|DirectorMerge|PRWorkflow', which proves the partial behavior but not the missing invariants above.

Related:

QA finding from the warded control plane coherence ops sweep on 2026-07-15. Issue #1275 was closed by replacement PR #1337, but the merged implementation only partially satisfies the issue's explicit decision for headless carry. This is a replacement issue with the same labels because the original P0 coherence-core acceptance was not fully met. What PR #1337 did land: - A shared `human_feedback.go` helper. - Director merge eligibility blocking for newer human comments across linked issue and PR comments. - Native PR merge/reopen blocking for simple issue-comment cases. - Focused tests for director merge and native PR merge/reopen human-comment blocks. Remaining gaps against #1275: - `wardAuthoredComment` treats `forgeForgejo.gitPushUser()` as ward-authored before checking structured markers. The issue explicitly says the default ignored-author list is empty, users may not have bot accounts, and Ward core must not ship local bot assumptions. Automation should be identified by structured body markers by default, not by username. - There is no documented or implemented feedback-gate config surface for ignored authors or extensible marker classification. - The gate reads issue/PR comments, but the issue required issue comments, PR comments, reviews, and relevant issue/PR body update metadata where available. - `ward agent pr close` is not guarded by `prWorkflowHumanInterventionGuard`, even though #1275 lists closing an issue/PR-like terminal action as gated. If close is intentionally exempt, the contract needs to say so and explain why. - Terminal completion is only instructed in seed text. I did not find code-level enforcement preventing `WARD-OUTCOME: done` / final `WARDED_WORKFLOW` completion when newer human feedback exists. - Tests cover happy blocking for `@coilysiren`, but not the no-bot-user invariant where a comment authored by the configured push user without ward markers must still block. Acceptance: - Remove username-based default automation classification from `wardAuthoredComment`; by default, only structured ward marker-family comments are automation. - Add/verify a documented config extension point for ignored authors and/or additional automation markers, with default ignored authors empty. - Extend the gate to cover PR reviews and available issue/PR update metadata, or explicitly document unavailable Forgejo API gaps and fail conservatively. - Apply the gate to all terminal actions named by #1275, including PR close and terminal done/completion paths, or split any intentionally deferred surface into separate issues before closing this one. - Add tests proving a no-bot user flow: a plain human comment from the repo owner or configured push user blocks, while ward marker comments do not. - Keep the already-landed merge/reopen protections from PR #1337 intact. Evidence checked: - `cmd/ward/human_feedback.go` on current `main` contains `strings.EqualFold(..., forgeForgejo.gitPushUser())` in `wardAuthoredComment`. - `cmd/ward/agent_pr_workflow.go` uses the guard for merge/reopen but not close. - `cmd/ward/agent_workflow.go` updates prompt/seed text about terminal workflow comments, but I did not find a code gate for posting terminal completion. - Focused current-main test run passed: `go test ./cmd/ward -run 'Human|Feedback|Intervention|DirectorMerge|PRWorkflow'`, which proves the partial behavior but not the missing invariants above. Related: - #1275 - PR #1337
Author
Member

Ops dispatch note from 2026-07-15.

I attempted to dispatch this P0 replacement issue with Codex, but the Ward repo is currently at its per-repo engineer limit.

Attempts:

warded engineer coilyco-flight-deck/ward#1346 --harness codex --workflow pull-request-and-merge
warded engineer coilyco-flight-deck/ward#1346 --harness codex --workflow pull-request-and-merge --override-capacity
warded engineer --harness codex --workflow pull-request-and-merge --override-capacity coilyco-flight-deck/ward#1346

All three failed through the broker with:

repo engineer limit is reached for coilyco-flight-deck/ward: 3 active engineer(s) (limit 3); pass --override-capacity to exceed real running capacity

I also stopped the stale closed-issue engineer coilyco-flight-deck/ward#1224 first, but the per-repo limit remained full with valid active Ward runs. The issue is filed and ready for dispatch as soon as capacity clears. I am filing a separate ops issue for the apparent brokered --override-capacity propagation/acceptance failure.

Ops dispatch note from 2026-07-15. I attempted to dispatch this P0 replacement issue with Codex, but the Ward repo is currently at its per-repo engineer limit. Attempts: ```bash warded engineer coilyco-flight-deck/ward#1346 --harness codex --workflow pull-request-and-merge warded engineer coilyco-flight-deck/ward#1346 --harness codex --workflow pull-request-and-merge --override-capacity warded engineer --harness codex --workflow pull-request-and-merge --override-capacity coilyco-flight-deck/ward#1346 ``` All three failed through the broker with: ```text repo engineer limit is reached for coilyco-flight-deck/ward: 3 active engineer(s) (limit 3); pass --override-capacity to exceed real running capacity ``` I also stopped the stale closed-issue engineer `coilyco-flight-deck/ward#1224` first, but the per-repo limit remained full with valid active Ward runs. The issue is filed and ready for dispatch as soon as capacity clears. I am filing a separate ops issue for the apparent brokered `--override-capacity` propagation/acceptance failure.
Author
Member

Dispatch retry from the QA/ops director at 2026-07-15T08:11Z is still blocked by repo capacity.

Command attempted: warded engineer coilyco-flight-deck/ward#1346 --harness codex --workflow pull-request-and-merge.

Broker response: repo engineer limit reached for coilyco-flight-deck/ward, 3 active engineer(s), limit 3. The available slot was consumed by newly filed operational repair #1352 before this retry completed.

Dispatch retry from the QA/ops director at 2026-07-15T08:11Z is still blocked by repo capacity. Command attempted: `warded engineer coilyco-flight-deck/ward#1346 --harness codex --workflow pull-request-and-merge`. Broker response: repo engineer limit reached for `coilyco-flight-deck/ward`, 3 active engineer(s), limit 3. The available slot was consumed by newly filed operational repair #1352 before this retry completed.
Author
Member

WARDED_WORKFLOW: #1356

details

workflow: pull-request-and-merge; review summary: skipped (in-container review gate intentionally skipped because the temporary ward default pending brokered QA)
felt: tight and linear
confidence: high
surprises: the PR merged before the final comment step
follow-ups: none

WARDED_WORKFLOW: https://forgejo.coilysiren.me/coilyco-flight-deck/ward/pulls/1356 <details><summary>details</summary> workflow: pull-request-and-merge; review summary: skipped (in-container review gate intentionally skipped because the temporary ward default pending brokered QA) felt: tight and linear confidence: high surprises: the PR merged before the final comment step follow-ups: none </details>
Author
Member

QA verification after merged PR #1356 on 2026-07-15.

Checked current origin/main (369495a36e83272141e0b25879c44d0cf8196d3a) against this replacement issue acceptance:

  • wardAuthoredComment no longer treats forgeForgejo.gitPushUser() as automation by default; automation defaults to structured ward markers.
  • agent.human-feedback.ignore-authors and automation-markers are implemented through ~/.ward/config.yaml, with docs stating ignore-authors starts empty.
  • The gate now combines linked issue comments, PR comments, PR UpdatedAt, and linked issue UpdatedAt; docs explicitly note Forgejo review records are not surfaced by the current client.
  • Native PR merge, close, and reopen all call prWorkflowHumanInterventionGuard before terminal action.
  • Director merge/record-done and backlog outcome parsing now fail closed when newer human feedback lacks a newer ward acknowledgement.
  • Tests cover the no-bot-user invariant, config extension, PR close blocking, and terminal/outcome blocking.

Focused verification run:

go test ./cmd/ward -run 'Human|Feedback|Intervention|DirectorMerge|PRWorkflow|Terminal|Done|Close' -count=1

Result: passed. This satisfies #1346; no replacement issue needed.

QA verification after merged PR #1356 on 2026-07-15. Checked current `origin/main` (`369495a36e83272141e0b25879c44d0cf8196d3a`) against this replacement issue acceptance: - `wardAuthoredComment` no longer treats `forgeForgejo.gitPushUser()` as automation by default; automation defaults to structured ward markers. - `agent.human-feedback.ignore-authors` and `automation-markers` are implemented through `~/.ward/config.yaml`, with docs stating `ignore-authors` starts empty. - The gate now combines linked issue comments, PR comments, PR `UpdatedAt`, and linked issue `UpdatedAt`; docs explicitly note Forgejo review records are not surfaced by the current client. - Native PR merge, close, and reopen all call `prWorkflowHumanInterventionGuard` before terminal action. - Director merge/record-done and backlog outcome parsing now fail closed when newer human feedback lacks a newer ward acknowledgement. - Tests cover the no-bot-user invariant, config extension, PR close blocking, and terminal/outcome blocking. Focused verification run: ```bash go test ./cmd/ward -run 'Human|Feedback|Intervention|DirectorMerge|PRWorkflow|Terminal|Done|Close' -count=1 ``` Result: passed. This satisfies #1346; no replacement issue needed.
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
coilyco-flight-deck/ward#1346
No description provided.