feat(studio): save eval run logs and fix active run status icon#1241
Merged
Conversation
- Capture spawned eval process stdout/stderr to <run-dir>/console.log so the output survives after the in-memory buffer is pruned, including for runs that crashed before producing any results. - Add GET /api/runs/:filename/log (both unscoped and benchmark-scoped) to serve the captured log; 404 when no log was written (remote runs or pre-feature local runs). - Surface live run status from the in-memory tracker on /api/runs so the RunList can render a pulsing cyan dot for starting/running runs instead of a misleading red ✗ when pass_rate is still 0. - Add a collapsible "Console Log" section in RunDetail that auto-hides when no log is available and live-streams while the run is active. Closes #1240 Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Deploying agentv with
|
| Latest commit: |
8defd6d
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://98d82498.agentv.pages.dev |
| Branch Preview URL: | https://feat-1240-run-logs-active-st.agentv.pages.dev |
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.
Summary
<run-dir>/console.logand serve it viaGET /api/runs/:filename/log(unscoped + benchmark-scoped) so the output survives after the in-memory buffer is pruned, including for runs that crashed early./api/runsso the RunList renders a pulsing cyan dot forstarting/runningruns instead of the misleading red ✗ produced whenpass_rateis still 0.Closes #1240
Test plan
bun run typecheckbun run lintbun run test— 1764 + 67 + 539 tests pass (0 fail)bun --filter ./apps/studio run build)/api/runsentry haspass_rate: 0so the RunList renders a red ✗; finished runs have noconsole.logto inspect./tmp/agentv-uat-1240viaPOST /api/eval/run. While running,/api/runsreturns"status":"running"andpass_rate: 0(frontend now renders the pulsing dot). After completion,console.log(2434 bytes) exists in the run dir andGET /api/runs/<id>/logreturns the captured output (eval progress + summary).GET /api/runs/<unknown>/logreturns 404 → frontend hides the section.🤖 Generated with Claude Code