---
name: "Show agent logs for a story in expanded work item"
---

# Story 235: Show agent logs for a story in expanded work item

## User Story

As a user, I want to see agent logs for a story inside its expanded view, so that I can monitor agent progress without switching context.

## Acceptance Criteria

- [ ] Expanded work item shows recent agent log output when an agent is assigned
- [ ] Logs update as the agent produces new output
- [ ] Shows agent status (running, completed, failed)

## Out of Scope

- TBD

## Test Results

<!-- huskies-test-results: {"unit":[{"name":"shows placeholder when no agent is assigned to the story","status":"pass","details":null},{"name":"shows agent name and running status when agent is running","status":"pass","details":null},{"name":"shows log output when agent emits output events","status":"pass","details":null},{"name":"appends multiple output events to the log","status":"pass","details":null},{"name":"updates status to completed after done event","status":"pass","details":null},{"name":"shows failed status after error event","status":"pass","details":null},{"name":"shows completed agent status without subscribing to stream","status":"pass","details":null},{"name":"shows failed agent status for a failed agent without subscribing to stream","status":"pass","details":null},{"name":"shows agent logs section (not placeholder) when agent is assigned","status":"pass","details":null}],"integration":[]} -->

### Unit Tests (9 passed, 0 failed)

- ✅ shows placeholder when no agent is assigned to the story
- ✅ shows agent name and running status when agent is running
- ✅ shows log output when agent emits output events
- ✅ appends multiple output events to the log
- ✅ updates status to completed after done event
- ✅ shows failed status after error event
- ✅ shows completed agent status without subscribing to stream
- ✅ shows failed agent status for a failed agent without subscribing to stream
- ✅ shows agent logs section (not placeholder) when agent is assigned

### Integration Tests (0 passed, 0 failed)

*No integration tests recorded.*
