fix: bug: dev-poll exits early when another agent has any in-progress issue, blocking parallel agents from claiming backlog (#572)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
e46c367bd5
commit
c096373ef6
1 changed files with 5 additions and 4 deletions
|
|
@ -426,6 +426,7 @@ ORPHANS_JSON=$(curl -sf -H "Authorization: token ${FORGE_TOKEN}" \
|
||||||
|
|
||||||
ORPHAN_COUNT=$(echo "$ORPHANS_JSON" | jq 'length')
|
ORPHAN_COUNT=$(echo "$ORPHANS_JSON" | jq 'length')
|
||||||
BLOCKED_BY_INPROGRESS=false
|
BLOCKED_BY_INPROGRESS=false
|
||||||
|
OTHER_AGENT_INPROGRESS=false
|
||||||
if [ "$ORPHAN_COUNT" -gt 0 ]; then
|
if [ "$ORPHAN_COUNT" -gt 0 ]; then
|
||||||
ISSUE_NUM=$(echo "$ORPHANS_JSON" | jq -r '.[0].number')
|
ISSUE_NUM=$(echo "$ORPHANS_JSON" | jq -r '.[0].number')
|
||||||
|
|
||||||
|
|
@ -478,13 +479,13 @@ if [ "$ORPHAN_COUNT" -gt 0 ]; then
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
log "issue #${ISSUE_NUM} assigned to ${assignee} — their thread, not blocking"
|
log "issue #${ISSUE_NUM} assigned to ${assignee} — their thread, not blocking"
|
||||||
BLOCKED_BY_INPROGRESS=true
|
OTHER_AGENT_INPROGRESS=true
|
||||||
# Issue assigned to another agent — don't block, fall through to backlog
|
# Issue assigned to another agent — skip stale checks but fall through to backlog
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Only proceed with in-progress checks if not blocked by another agent
|
# Only proceed with in-progress checks if not blocked by this agent's own work
|
||||||
if [ "$BLOCKED_BY_INPROGRESS" = false ]; then
|
if [ "$BLOCKED_BY_INPROGRESS" = false ] && [ "$OTHER_AGENT_INPROGRESS" = false ]; then
|
||||||
# Check for dev-agent lock file (agent may be running in another container)
|
# Check for dev-agent lock file (agent may be running in another container)
|
||||||
LOCK_FILE="/tmp/dev-impl-summary-${PROJECT_NAME}-${ISSUE_NUM}.txt"
|
LOCK_FILE="/tmp/dev-impl-summary-${PROJECT_NAME}-${ISSUE_NUM}.txt"
|
||||||
if [ -f "$LOCK_FILE" ]; then
|
if [ -f "$LOCK_FILE" ]; then
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue