Allow agent/fix workflow to work on non-agent PRs - #59
Conversation
There was a problem hiding this comment.
Review Summary
The core changes are correct and achieve the stated goal of allowing the fix workflow to operate on non-agent PRs. The conditional logic was properly updated and the lockfile was correctly recompiled. However, there's a stale documentation issue that needs to be addressed.
Issues Found
Stale Documentation Reference
Location: .github/workflows/fix.md:165-172
The explanatory note still references the removed branch-prefix check:
Note: this workflow uses a plain `pull_request: types: [labeled]` trigger
gated by `if:` rather than gh-aw's `label_command:` trigger, because
`label_command:` combined with a custom top-level `if:` (needed here for
the `agent/` branch-prefix check) silently drops its own label-name match
condition, which would make this workflow fire on *any* label added to an
`agent/`-branch PR.The phrase "needed here for the agent/ branch-prefix check" is now incorrect since that check was removed in this PR.
Fix needed: Update or remove this note to reflect the current state. Either:
- Remove the outdated reference: "...gated by
if:rather than gh-aw'slabel_command:trigger to maintain manual label consumption and prevent duplicate re-triggers." - Or investigate whether the workflow should now use
label_command:instead of the plain trigger, since there's no longer a custom branch check.
What I Checked
✅ Conditional logic correctly updated in both source and lockfile
✅ All instances of startsWith(github.event.pull_request.head.ref, 'agent/') removed
✅ Descriptions updated from "agent-authored pull request" to "pull request"
✅ Lockfile properly recompiled with updated metadata hash
✅ Changes align with issue #57 requirements
✅ No security or correctness issues in the core logic
|
Commit pushed:
|
There was a problem hiding this comment.
Review Complete ✓
I've reviewed the changes to remove the branch name prefix restriction from the fix workflow.
Changes validated:
- ✅ Source and compiled workflow files are synchronized
- ✅ Branch prefix check removed from all trigger conditions
- ✅ Description strings updated consistently
- ✅ Safety mechanisms preserved (iteration cap, label consumption, repo ownership check)
- ✅ Metadata hash confirms successful recompilation
- ✅ Documentation updated to remove obsolete branch-prefix explanation
Scope correctly limited: Only fix.md was modified - review.md and merge.yml intentionally retain their agent/ branch restrictions for safety.
This correctly addresses issue #57, enabling the fix workflow to help with human-authored PRs while maintaining appropriate restrictions on auto-review and auto-merge.
|
Needs rebase |
|
Commit pushed:
|
There was a problem hiding this comment.
Code Review - Approved
I've reviewed this PR for correctness, quality, safety, and adherence to repository conventions.
What I checked
Correctness:
- ✅ fix.md correctly removes the branch name restriction (
startsWith(github.event.pull_request.head.ref, 'agent/')) - ✅ drafter.md correctly adds label propagation logic (steps 6-7) to pass
agent/workflow-edits-allowedfrom issues to PRs - ✅ Both lockfiles properly recompiled with updated metadata hashes
- ✅ Condition changes applied consistently throughout fix.lock.yml
Safety:
- ✅ Fork protection maintained (
github.event.pull_request.head.repo.id == github.repository_id) - ✅ Bot-only trigger enforcement via
bots:filter - ✅ No new security risks introduced
Quality:
- ✅ Changes are minimal and focused
- ✅ Workflow instructions clear and specific
- ✅ Documentation accurately reflects new behavior
Cohesion:
Both changes work together to fully address issue #57:
- fix.md changes enable the workflow to process any PR labeled
agent/fixme - drafter.md changes ensure the
agent/workflow-edits-allowedlabel flows from issues to PRs, allowing fix.md to modify protected workflow files
This PR is ready to merge.
|
There's lock drift here |
Automated Fix Loop: Iteration Limit ReachedThe automated fix loop has reached its iteration limit of 3 commits on this PR branch. Automated fixing has stopped to prevent runaway iterations. What this means:
Next steps:A human reviewer should:
Important note about the iteration cap:Re-applying the The only way to continue the automated loop is to reduce the branch's commit count below 3 first (e.g., by squashing commits), but this is typically not recommended. Manual intervention is the intended path forward at this point.
|
cefd31d to
4d8f566
Compare
Permit the fix iteration loop to address any same-repository pull request labeled agent/fixme, rather than silently skipping human-authored branches. Keep the prompt documentation and compiler-owned lock metadata synchronized with that behavior. Fixes: #57 Assisted-by: AI Signed-off-by: Colin Walters <walters@verbum.org>
4d8f566 to
c69fe3c
Compare
Fixes #57
This PR removes the branch name prefix restriction from the
agent/fixworkflow, allowing it to work on any PR labeled withagent/fixme, not just those with branch names starting withagent/.Changes
startsWith(github.event.pull_request.head.ref, 'agent/')check from the workflow trigger conditionfix.lock.ymlto reflect the updated conditionValidation
The changes were validated by:
gh aw compile(no errors)This enables the use case described in #57 where agents can perform operations like rebasing on human-authored PRs.