Make pipelinerun/taskrun logs agent-friendly
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 461
- Forks
- 277
- Avg merge
- 16h 48m
- Merged PRs (30d)
- 95
Description
Summary
tkn pipelinerun logs and tkn taskrun logs are likely the most-used commands by AI agents debugging CI/CD failures. The current output is optimized for human consumption with color codes and interleaved multi-container output that's hard to parse programmatically.
Proposal
--output jsonfor structured log output with metadata (task name, step name, timestamp, message)- Ensure
--followworks well in non-interactive/agent contexts - Clear separation of log lines per step/container in structured mode
- Consider
--timestampsin a parseable format (RFC3339)
Example
tkn pipelinerun logs my-run --output json
{"task": "build", "step": "build-step", "timestamp": "2026-05-12T10:00:00Z", "message": "Building image..."}
{"task": "build", "step": "build-step", "timestamp": "2026-05-12T10:00:01Z", "message": "Successfully built abc123"}
NDJSON (one line per log entry) is the natural format here since logs are a stream.
/kind feature
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the implementations of tkn pipelinerun logs and tkn taskrun logs, then trace how log lines are collected, interleaved, colored, and followed. Define the structured NDJSON fields and parseable timestamp behavior from the proposal, including non-interactive --follow; done means both commands support agent-friendly structured output with clear task and step separation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli, devops
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100