Title: queue: task 11164 claimed by two lanes concurrently (code-a and code-x) — claim atomicity violated · Issue #6985 · developing-today/code · GitHub
Open Graph Title: queue: task 11164 claimed by two lanes concurrently (code-a and code-x) — claim atomicity violated · Issue #6985 · developing-today/code
X Title: queue: task 11164 claimed by two lanes concurrently (code-a and code-x) — claim atomicity violated · Issue #6985 · developing-today/code
Description: Problem Queue task 11164 (repo-health-code-pilot, triage of issue #6310) was claimed and worked by two worker lanes at the same time, despite the runbook's premise that "claiming is atomic across lanes". Evidence (2026-11-08, all times U...
Open Graph Description: Problem Queue task 11164 (repo-health-code-pilot, triage of issue #6310) was claimed and worked by two worker lanes at the same time, despite the runbook's premise that "claiming is atomic across l...
X Description: Problem Queue task 11164 (repo-health-code-pilot, triage of issue #6310) was claimed and worked by two worker lanes at the same time, despite the runbook's premise that "claiming is atomic...
Opengraph URL: https://github.com/developing-today/code/issues/6985
X: @github
Domain: github.com
IPv4 address: 140.82.113.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"queue: task 11164 claimed by two lanes concurrently (code-a and code-x) — claim atomicity violated","articleBody":"## Problem\n\nQueue task 11164 (repo-health-code-pilot, triage of issue #6310) was claimed and worked by two worker lanes at the same time, despite the runbook's premise that \\\"claiming is atomic across lanes\\\".\n\n## Evidence (2026-11-08, all times UTC)\n\n- Lane code-x (cron repo-queue-worker-shift-x, run started 2026-11-07 17:59 CST): claimed task 11164, triaged issue #6310, and posted its completion agent note on #6310 at 2026-11-08T00:05:58Z (note footer: `agent-note:v1 agent=repo-worker-code state=done task=11164 at=2026-11-08T00:08:00Z`).\n- Lane code-a (cron repo-queue-worker-shift, run started 2026-11-07 18:00 CST): `fleet queue claim --queue repo-health-code-pilot --worker repo-worker-code --lane code-a --lease-seconds 2700` returned task 11164 as a fresh claim in the same window; `fleet queue lane 11164` created lane ledger row 3413 at 2026-11-08T00:05:36Z with assigned_lane `direct`, and a `claimed` checkpoint was accepted.\n- Minutes later, lane code-a's heartbeat returned the verdict `heartbeat_task: task 11164 is not claimed by repo-worker-code` — the task had already reached its terminal state under the other lane's work. Lane code-a stopped per the runbook heartbeat-verdict rule and posted no duplicate note.\n\n## Why it matters\n\nThe atomic claim is the fleet's only protection against double work when lanes overlap by design (the lane locks are per-lane, not global). A double claim wastes two shifts on one task and risks divergent writes (notes, labels, terminal verbs) on the same issue; here the collision was visible only because both lanes post agent notes on the issue.\n\n## Acceptance criteria\n\n- [x] Reproduce or explain from queue event history how task 11164 came to be claimed by two lanes (concurrent claim race, completion-then-reclaim, or another path), with the task's claim/complete event rows cited.\n- [x] `claim_repo_task` (or its successor) cannot return a task that is already claimed-and-live or already terminal to a second claimer; a regression test or a documented invariant check covers the concurrent-claim case.\n- [x] If the root cause is that a completed task was re-presented, the claim path filters terminal tasks and the event history for task 11164 shows where the filter failed.\n\n## Verification (2026-11-23)\n\n- `fleet queue timeline 11164 --json` returns event **1792** (`claimed`, 2026-11-08T00:05:23Z) and event **1842** (`completed`, 2026-11-08T00:06:12Z). Together with the incident's lane code-a claim/ledger evidence at 00:05:36Z, this places code-a's second claim after the initial claim and before completion: a concurrent live-claim race, not completion-then-reclaim. The old history has no separate event for code-a's second claim, which is the observability defect; merged PR #10939 records refused live by-id claims and exposes displacement events in timelines.\n- The single-winner invariant is covered by merged PR #8107 (`claim_race_two_lanes_exactly_one_winner_per_task`, task 11895 fixture); PR #10939 adds the same-worker/two-lane refusal event; PR #11803 makes lifecycle verbs reject another lane's claim. On current main, `fleet shell --target local --cwd \"$PWD/pkgs/fleet\" -- cargo test -p fleet-queue --all-features claim_race_two_lanes_exactly_one_winner_per_task` passed (1 test).\n- The terminal-representation condition does not apply to this incident: the second-claim evidence predates event 1842. Current `default_pick_predicate` only selects queued, eligible parked, or eligible handoff work (`pkgs/fleet/crates/fleet-queue/src/turso_queue/claim.rs:2143-2153`); claimed and terminal statuses are excluded.","author":{"url":"https://github.com/dezren39","@type":"Person","name":"dezren39"},"datePublished":"2026-11-08T00:07:35Z","url":"https://github.com/developing-today/code/issues/6985"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:3cd07fc7-133f-db3f-bf7e-d86893aa21e2 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | CDE0:36611F:24695C:2F8202:6B06132E |
| html-safe-nonce | c330589b1f713173ee03f76497f8bc7a05432e45ab7d20c525970b586f894f0a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDREUwOjM2NjExRjoyNDY5NUM6MkY4MjAyOjZCMDYxMzJFIiwidmlzaXRvcl9pZCI6IjE1MTU1NTY2MjM2NTk4NzYzMCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | a55cac8a86e0d7350f19ca85199246eb10fe6f9d674b07fb47ea9de24e63a223 |
| hovercard-subject-tag | issue:6265689129 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/developing-today/code/6985/issue_layout |
| twitter:image | https://opengraph.githubassets.com/0948473725de05c54a92193cf698447fbbbad27c65332069cf510a1134fb653e/developing-today/code/issues/6985 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/0948473725de05c54a92193cf698447fbbbad27c65332069cf510a1134fb653e/developing-today/code/issues/6985 |
| og:image:alt | Problem Queue task 11164 (repo-health-code-pilot, triage of issue #6310) was claimed and worked by two worker lanes at the same time, despite the runbook's premise that "claiming is atomic across l... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | dezren39 |
| hostname | github.com |
| expected-hostname | github.com |
| None | e58943f0186bb8d97b217393c2724a49ab47e4aefefc43595a90fa04699066c9 |
| turbo-cache-control | no-preview |
| go-import | github.com/developing-today/code git https://github.com/developing-today/code.git |
| octolytics-dimension-user_id | 26439447 |
| octolytics-dimension-user_login | developing-today |
| octolytics-dimension-repository_id | 627308783 |
| octolytics-dimension-repository_nwo | developing-today/code |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 627308783 |
| octolytics-dimension-repository_network_root_nwo | developing-today/code |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 23517473abc6d5da019b4958bd421644e98a418b |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width