Skip to content

feat(traces): complete CLI trace contract#23

Merged
mrgoonie merged 2 commits into
devfrom
codex/complete-traces-cli-contract
Jun 11, 2026
Merged

feat(traces): complete CLI trace contract#23
mrgoonie merged 2 commits into
devfrom
codex/complete-traces-cli-contract

Conversation

@mrgoonie

Copy link
Copy Markdown
Contributor

Summary

  • Align traces list/get/follow/export with current GoClaw server trace contracts.
  • Add traces timeline <runID> for GET /v1/runs/{runID}/timeline.
  • Refresh trace fixtures/tests to server-shaped payloads and update docs/plans.

Details

  • traces list now preserves {traces,total,limit,offset} in JSON/YAML and renders rows from traces in table mode.
  • traces list supports server filters: --agent, --user, --session-key, --status, --channel, --limit, --offset.
  • Deprecated unsupported list flags --since and --root-only are hidden and rejected with validation errors.
  • traces get renders {trace,spans} with id, parent_span_id, and span_type.
  • traces export validates IDs and path-escapes route params before HTTP.
  • traces follow remains one-shot and shares server-field table rendering.
  • No traces replay command added because server dev does not expose replay.

Validation

  • /usr/local/go/bin/go test -count=1 ./cmd -run 'TestTraces(List|Get|Follow|Timeline|Export)'
  • /usr/local/go/bin/go test -count=1 ./cmd ./internal/client ./internal/output
  • /usr/local/go/bin/go test -count=1 ./...
  • /usr/local/go/bin/go vet ./...
  • /usr/local/go/bin/go build ./...
  • git diff --check

Notes

  • Local shell did not have go on PATH; validation used /usr/local/go/bin/go (go1.25.3 darwin/arm64).
  • Supersedes the older flat-fixture trace detail plan for implementation details.

Closes #17.

@mrgoonie mrgoonie merged commit ab210b9 into dev Jun 11, 2026
3 checks passed
@mrgoonie mrgoonie deleted the codex/complete-traces-cli-contract branch June 11, 2026 16:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant