Harden agent-team apply: reject bad diffs, list draft PRs via App #73
No reviewers
Labels
No labels
app
bug
ci
compliance
content
dependencies
docs
documentation
duplicate
enhancement
github_actions
good first issue
help wanted
infra
invalid
javascript
needs-triage
python
question
tests
wontfix
No milestone
No project
No assignees
1 participant
Due date
No due date set.
Dependencies
No dependencies set.
Reference: adam/orchestrator#73
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "fix/agent-team-builder-validation-and-app-monitor"
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?
Summary
Two reliability bugs in the agent-team apply pipeline, found investigating a blank draft PR (#72) and a README task that died silently:
build_candidate_diffaccepted any non-empty diff string. A diff with placeholder hunk headers (@@ -X,Y +A,B @@) was dispatched and rejected bygit apply(exit 128) — the task parked with an opaque error; a diff that only created an empty file applied cleanly and opened a blank draft PR (#72). Now a pure shape check fails at build with an actionable reason when a hunk header is non-numeric or the patch has no content.gh, which is not installed on the R720.gh pr listraisedFileNotFoundErrorevery 30s tick, so the runaway/stale monitor was permanently blind. Reuse the App installation-token REST path the dispatcher already uses (GET …/pulls, filtered to draft PRs underagent-team/apply/); fall back toghonly where the App env is absent.Validation
python -m pytest -q→ 1533 passedruff check/ruff format --check→ cleanapp_draft_pr_listerfiltering, fail-soft on auth error, and token-scrubbing on transport error.Notes
/sh-deploy-r720procedure (Hyper-V snapshot is Adam's manual step); this PR is not auto-deployed./sh-security-review).Closing: agent-team is being decommissioned (superseded by Open SWE). See removal PR.