Repository navigation
feat(tasks): show background shell and subagent output in /tasks detail panel - #897
Merged
Merged
Conversation
…il panel Add JobOutputProvider interface to domain/background_job.go so jobs can expose their captured output for the /tasks detail panel. Implement it on shellJob (reads from OutputRingBuffer) and headlessSubagentJob (stores the final result). Update Supervisor.Snapshot() to populate the Output field on TrackedJob when the job implements JobOutputProvider. Update the task management view to render the output section for shell and subagent rows, bounded to 10KB to prevent a chatty shell from blowing up the panel.
…y in /tasks Adds supervisor integration tests (TestSupervisor_SnapshotPopulatesOutput, TestSupervisor_SnapshotOmitsOutputForNonProvider, TestSupervisor_SnapshotPopulatesOutputAfterCleanupReap) verifying the JobOutputProvider -> Snapshot -> TrackedJob.Output data path. Adds a tmux-based e2e test (TestChatTUIBackgroundShellOutput) that drives the real chat TUI, triggers a detached background shell via a new mock scenario, opens /tasks, and asserts the rendered Output section contains the captured stdout. Adds background-shell mock scenario to scenarios.yaml for deterministic testing of detached Bash output.
…es in mock anchoring
…e output in /tasks
3 tasks
Contributor
|
🎉 This PR is included in version 0.146.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Resolves #692
Summary
Adds a new
Outputsection to the/tasksdetail panel for background shell and subagent rows, showing the captured stdout/stderr (for shells) or final result message (for subagents). Previously only A2A tasks showed their result in the detail panel; shells and subagents showed only metadata. The output is bounded to 10KB to prevent a chatty shell from blowing up the panel.Changes
JobOutputProviderinterface todomain/background_job.go- an optional extension that jobs implement to expose their captured output for the detail panelOutputfield toTrackedJobso the supervisor snapshot carries the output textJobOutputProvideronshellJob- reads from the shell'sOutputRingBuffer(the full captured stdout/stderr)JobOutputProvideronheadlessSubagentJob- stores and returns the subagent's final result messageSupervisor.Snapshot()to check forJobOutputProviderand populate theOutputfieldOutputfield toTaskInfoand populate it injobToTaskInfo()renderJobOutput()method to the task management view - renders the output section with a 10KB truncation bound, matching the A2A "Final Result" panel style