Skip to content

fix(telemetry): Align attributes with OTel semantics#307

Merged
dcramer merged 7 commits into
mainfrom
docs/telemetry-map
May 11, 2026
Merged

fix(telemetry): Align attributes with OTel semantics#307
dcramer merged 7 commits into
mainfrom
docs/telemetry-map

Conversation

@dcramer
Copy link
Copy Markdown
Member

@dcramer dcramer commented May 11, 2026

Align Warden telemetry names around OpenTelemetry semantics and one canonical query shape.

Repository, source-code, CI/CD, and GenAI agent metadata now use the matching OTel semantic attributes where they exist. Warden-owned concepts such as triggers, hunks, findings, extraction, fix gate, deduplication, and fix evaluation are consistently namespaced under warden.* across spans, logs, and metrics.

The root telemetry map points at Junior’s shared telemetry spec and includes recipes for repository-scoped finding totals by skill using gen_ai.agent.name with vcs.owner.name and vcs.repository.name. The metrics no longer emit compatibility aliases like raw skill, model, severity, findings.total, or tokens.input.

Added focused tests for the Sentry telemetry helpers so repository scope, GitHub Actions scope, and skill metrics keep the OTel/Warden split intact.

Add a root telemetry investigation map for Warden production incidents.

The map points to the shared Junior telemetry spec and gives Sentry query
pivots for CLI runs, GitHub Action workflows, skill analysis, GenAI spans,
finding processing, and fix evaluation.

Co-Authored-By: GPT-5 <noreply@anthropic.com>
Add the direct Sentry Metrics recipe for finding total counts by skill and repository.

This makes the skill metric dimension explicit for agents using the telemetry map.

Co-Authored-By: GPT-5 <noreply@anthropic.com>
Use OTel semantic attributes for repository, source-code, CI/CD, and GenAI agent metadata. Namespace Warden-specific metrics and span attributes under warden.* so spans and metrics share one canonical query shape.

Co-Authored-By: GPT-5 <noreply@anthropic.com>
@dcramer dcramer changed the title docs: Add telemetry query map fix(telemetry): Align attributes with OTel semantics May 11, 2026
@dcramer dcramer marked this pull request as ready for review May 11, 2026 20:55
Add the root telemetry investigation map to AGENTS.md so agents can discover the Sentry query guide while working in the repository.

Co-Authored-By: GPT-5 <noreply@anthropic.com>
@dcramer dcramer marked this pull request as draft May 11, 2026 20:57
@dcramer dcramer marked this pull request as ready for review May 11, 2026 20:57
Comment thread src/cli/output/tasks.ts Outdated
Only set warden.trigger.name when a skill task came from an actual trigger. Direct CLI skill runs now carry gen_ai.agent.name without synthetic trigger metadata.

Remove telemetry-specific tests from the PR.

Co-Authored-By: GPT-5 <noreply@anthropic.com>
Comment thread src/action/workflow/pr-workflow.ts Outdated
The action now sets github.event.name once on the global Sentry scope. Remove the duplicate workflow span assignment so telemetry uses the shared scope.

Co-Authored-By: GPT-5 Codex <noreply@anthropic.com>
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 997bad4. Configure here.

Comment thread src/sentry.ts Outdated
Use the GitHub Actions server URL for repository telemetry URLs so GHES runs do not point at github.com while run URLs point at the enterprise host.

Add regression coverage for both GHES and default github.com URL construction.

Co-Authored-By: GPT-5 Codex <noreply@anthropic.com>
@dcramer dcramer merged commit 6de4dd9 into main May 11, 2026
15 checks passed
@dcramer dcramer deleted the docs/telemetry-map branch May 11, 2026 21:52
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