bug: dev-bot and dev-qwen race for the same backlog issues #160
Labels
No labels
action
backlog
blocked
bug-report
in-progress
prediction/actioned
prediction/dismissed
prediction/unreviewed
priority
tech-debt
underspecified
vision
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: disinto-admin/disinto#160
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Problem
Both
dev-bot(Anthropic agents container) anddev-qwen(llama agents container) run dev-poll against the same backlog. They can both claim the same issue simultaneously. When one creates a PR, the other's stale-branch detection (#148) closes it, causing aclosed_externallyblock.Observed on issue #158: dev-bot claimed it and created PR #159. Dev-qwen's stale branch detection then closed the PR. Dev-bot saw the PR closed externally and blocked the issue.
Root cause
There is no exclusive assignment mechanism between the two agents. Both poll the same Forgejo backlog, both check for
backloglabel, both try to claim by addingin-progress.The assignee mechanism (
issue_claimassigns the bot user) provides a soft lock, but the two agents don't check each other's assignments — dev-qwen only skips issues assigned todev-botin the "checking for in-progress issues" phase, not during backlog scanning.Fix options
The simplest fix: dev-poll should check the issue assignee before claiming. If an issue is already assigned to a different bot user, skip it.
In
dev/dev-poll.sh, during backlog scanning, add:Where
FORGE_USERis the current agent's identity (resolved from the token).Affected files
dev/dev-poll.sh— backlog scanning sectionAcceptance criteria