Show background task progress between Session turns - #1786
Conversation
There was a problem hiding this comment.
All reported issues were addressed across 12 files
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
7ee21dc to
ceb5fd2
Compare
|
/kelos review |
|
🤖 Kelos Task Status Task |
|
🤖 Kelos Reviewer Agent @gjkim42 Review SummaryVerdict: APPROVE Findings Overview
FindingsCorrectness
Suggestions (optional)
Key takeaways (optional)
|
ceb5fd2 to
6c0dd87
Compare
|
Addressed the Kelos review in
|
There was a problem hiding this comment.
All reported issues were addressed across 4 files (changes from recent commits).
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
6c0dd87 to
d3e6a82
Compare
What type of PR is this?
/kind bug
What this PR does / why we need it:
When a Claude Code Session finishes a turn while background work continues, its progress indicator disappears and only the generic Active status remains. Show the reported background-task count in the Console and interactive terminal so users can tell that work is still running.
2 background tasks runningand keep the composer available for another message.Working,Waiting for input, orInterrupting.The count comes from Claude's task lifecycle events and excludes internal housekeeping. It covers reported subagents and background commands; it does not infer that the parent is blocked on a particular task. Providers without this telemetry keep their existing turn progress display.
Before — background work continues after the parent turn
After — the same Session state
After — an active turn with one background task remaining
Screenshots use the actual Console with sample Session API responses and WebSocket events. The before/after comparison uses the same conversation and activity state; these are not captures of a live agent run.
Which issue(s) this PR is related to:
N/A
Special notes for your reviewer:
Background counts travel through the existing live runtime-status stream, outside retained conversation history. The same reported count drives Session activity and idle-drain handling. Partial model/usage updates preserve the count, and the connection snapshot includes the current value.
Validation:
make updatemake build WHAT=cmd/kelos-session-runtimeenv -u CODEX_AUTH_JSON -u CODEX_HOME make test TEST_FLAGS='-timeout=120s'make verify, includinggo vetThe unit suite unsets inherited
CODEX_AUTH_JSONandCODEX_HOMEbecause they interfere with existing entrypoint tests. E2e coverage also checks the completed background count in reconnect status.Does this PR introduce a user-facing change?
Summary by cubic
Shows the reported Claude Code background-task count in the Console and interactive terminal so progress remains visible after a turn ends.
N background tasks runningbetween turns; during a turn the count appears alongsideWorking,Waiting for input, orInterrupting.provider.backgroundevent is removed.Written for commit d3e6a82. Summary will update on new commits.