Skip to content

Dashboard: a run that left packs alive is no full clear - #302

Merged
pjerra merged 4 commits into
devfrom
fix/run-left-not-complete
Oct 23, 2026
Merged

pjerra merged 4 commits into
devfrom
fix/run-left-not-complete

Conversation

@pjerra

@pjerra pjerra commented Oct 23, 2026

Copy link
Copy Markdown
Owner

The TortoiseBots run leader now adds an optional trailing field to its status line when it left packs alive: TBM:RUN|...|<note>|left <K> (only when K > 0; TortoiseBots branch fix/defer-unreachable-pack). Until now the agent folded it into the note and the dashboard counted such a run as a full clear.

  • internal/tbm: ParseRunLine reads a trailing left <digits> into RunStatus.Left and strips it from the note; lines without it parse as before.
  • internal/dashboard: a run is complete only as a confirmed clean clear (reason == "done", from the first leg, Left == 0), one helper used by Complete and by the ghost's tie-break; every run_leader event sets the count, so a later zero clears an earlier one; the dashboard shows the packs left.
  • internal/dungeon: observe mode carries the count through.

Tests: parser with and without the field, a note with "left" text, a count that drops to zero, ghost tie-breaks (clean vs dirty, aborted vs done). make test passes.

Reviews: three Codex rounds, each finding fixed (stale count, ghost tie-break, aborted runs counted as clean).

@pjerra
pjerra marked this pull request as ready for review October 23, 2026 22:40
@pjerra
pjerra merged commit 567b392 into dev Oct 23, 2026
2 checks passed
@pjerra pjerra mentioned this pull request Oct 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant