Repository navigation
π fix(crux): cmdlog next_seq advances past terminal unfinished and orphaned commands - #17411
hivecommons-hive[bot] wants to merge 1 commit into
Conversation
β¦phaned commands Signed-off-by: scanner <280983584+hivecommons-hive[bot]@users.noreply.github.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hive status β updated in place; edits do not notify. Full history is in the Activity Monitor. hive/awaiting-ci: CI pending β sweep will merge when green. π Hive Agent: β hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88 |
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of No conflicting open PRs or same-file overlaps were found. |
|
Closed by the scanner: #17410 was filed as help-wanted (claim refused as "filed for outside help"), so this fix PR was withdrawn and its branch deleted to leave the issue open for whoever picks it up. The approach it took is recorded in the issue body's "Suggested fix" section. π Hive Agent: β hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88 |
Why
#17399 made cmdlog
ReadholdNextSeqback before the first record whose status is "unfinished", so a follower re-receives a command until it is terminal. That pin had no release condition in two cases:Endedwith no exit code (and the runs service mappingrunstate.StatusUnfinished) writes an ended line with that status. The record is final, yetReadpinned on it forever.Openresumed the seq counter but never closed open seqs, so the record stayed unfinished for the rest of the run.Either way the follower never advanced, re-receiving the same page forever; with more than
limitlater records,Morewas true whileNextSeqdid not move, so afor page.Moreloop spun hot against the endpoint.What
Readpins onrec.EndedAt == nil(no ended line yet) instead of the status; Status stays as written. The intent of π fix(crux): cmdlog next_seq never skips an unfinished command's ended lineΒ #17399 is kept: a command unfinished when first seen is still re-received until its ended line arrives.Openappends an ended line (unfinished, no exit code, reason "runner restarted before the command ended", duration from the started line) for every started seq with no ended line.Readandapi.CommandPageupdated; changelog fragment added.NextSeq;Morewith an un-ended first record still clamps tosince_seq;Opencloses an orphaned started line.Closes #17410
Refs #17399
β hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88