You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(explore): use tracemetrics dataset instead of metricsEnhanced (#995)
`--dataset metrics` and `--metric` auto-resolver were sending
`dataset=metricsEnhanced` to the Events API, which routes to the legacy
`metrics_enhanced_performance` backend. SDK v10 trace metrics live in
the `tracemetrics` dataset (backed by `TraceMetrics`), which is what the
Sentry Explore Metrics UI uses. Switched all metrics-related API calls
to `tracemetrics`.
## Testing
`bun test test/commands/explore.test.ts` — 37/38 pass (1 pre-existing
failure from missing `api-schema.json`).
`bun test test/types/dashboard.test.ts` — 96/96 pass.
`bun test test/commands/dashboard/resolve.test.ts` — 76/76 pass.
`bun test test/lib/metrics-transform.test.ts` — 10/10 pass.
Fixes#994
<!--
## Plan
Root cause: the Sentry Events API has two distinct dataset values for
metrics:
- `metricsEnhanced` → `metrics_enhanced_performance` (legacy
DDM/release-health)
- `tracemetrics` → `TraceMetrics` (SDK v10 trace metrics, used by
Explore Metrics UI)
The CLI was sending `metricsEnhanced` everywhere, which can't find SDK
v10 metrics.
Changes:
1. `src/commands/explore.ts` — DATASET_ALIASES maps `metrics` →
`"tracemetrics"`, all internal comparisons updated
2. `src/lib/api/discover.ts` — `queryMetricsMeta` uses `dataset:
"tracemetrics"`
3. `src/types/dashboard.ts` — `WIDGET_TYPE_TO_DATASET` maps
`tracemetrics` → `"tracemetrics"`
4. Comments and tests updated to match
-->
0 commit comments