Repository navigation
fix(kanban): don't flag dispatcher stuck when ready tasks are respawn-guard deferred (#80513) - #91941
Closed
Enough1122 wants to merge 2 commits into
Closed
Enough1122 wants to merge 2 commits into
Enough1122 wants to merge 2 commits into
Conversation
Related: #44899 is an earlier open fix for respawn-guarded tasks being counted as spawnable. This PR overlaps that ready-lane repair and additionally covers review-lane telemetry and diagnostic context; maintainers should choose or consolidate the approaches. |
Author
|
Closing as part of an open-queue triage — consolidating my open work so review attention goes to the highest-value changes. Nothing here is abandoned: happy to reopen (or rebase fresh) if there's interest or reviewer bandwidth. |
12 of 19 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #80513
Root cause
The dispatcher health telemetry's has_spawnable_ready() counted ready+assigned+unclaimed tasks without consulting the respawn guard — but dispatch_once deliberately defers exactly those tasks every tick (recent_success / active_pr / rate_limit_cooldown / blocker_auth). An idle-by-design board therefore read as "spawnable work waiting", producing endless false "kanban dispatcher stuck" alarms (~986 false ticks observed by the reporter).
Fix
Both probes (has_spawnable_ready + mirror has_spawnable_review) now route through a shared _has_spawnable_in_lane(): a task counts as spawnable only when its assignee is a real profile AND check_respawn_guard() does not defer it this tick. Unexpected guard errors fail conservative (legacy warn behavior preserved), and both warn sites (CLI daemon + gateway watcher) now annotate the warning with that tick's guard deferrals so operators can split parked tasks from genuinely broken spawns. Dispatch semantics untouched — the probes' only callers are the two telemetry warn sites.
Verification