Skip to content

fix(local): surface trace events inline in sentry local run#1105

Open
jared-outpost[bot] wants to merge 1 commit into
mainfrom
issue-1099-surface-trace-events-inline
Open

fix(local): surface trace events inline in sentry local run#1105
jared-outpost[bot] wants to merge 1 commit into
mainfrom
issue-1099-surface-trace-events-inline

Conversation

@jared-outpost

@jared-outpost jared-outpost Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

When sentry local run auto-starts a background server, it now subscribes to the spotlight buffer with formatEnvelopeLines so envelope items (transactions, errors, logs) are printed to the terminal — matching the behavior of sentry local serve.

Previously the buffer was created but never subscribed to, so the only inline feedback was logger messages like "Background server listening on ...". Users had to run sentry local serve in a separate terminal to see event details.

Testing

  • Formatter tests pass (vitest run test/lib/formatters/local.test.ts test/lib/formatters/local.property.test.ts — 74/74)
  • tsc --noEmit clean on changed file (pre-existing failures in sdk.generated.js and api.ts -H alias are unrelated)
  • biome check clean

Closes #1099

When `sentry local run` auto-starts a background server, subscribe to
the spotlight buffer so incoming envelopes are formatted and printed
to the terminal — matching the behavior of `sentry local serve`.

Previously the buffer silently collected envelopes without printing
them, so users only saw a high-level confirmation message.

Fixes #1099
@github-actions

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://cli.sentry.dev/_preview/pr-1105/

Built to branch gh-pages at 2026-06-15 22:20 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

@github-actions

Copy link
Copy Markdown
Contributor

Codecov Results 📊

❌ Patch coverage is 70.00%. Project has 5015 uncovered lines.
✅ Project coverage is 81.19%. Comparing base (base) to head (head).

Files with missing lines (1)
File Patch % Lines
src/commands/local/run.ts 70.00% ⚠️ 6 Missing and 1 partials
Coverage diff
@@            Coverage Diff             @@
##          main       #PR       +/-##
==========================================
+ Coverage    81.19%    81.19%        —%
==========================================
  Files          383       383         —
  Lines        26651     26661       +10
  Branches     17354     17356        +2
==========================================
+ Hits         21638     21646        +8
- Misses        5013      5015        +2
- Partials      1798      1799        +1

Generated by Codecov Action

@jared-outpost jared-outpost Bot marked this pull request as ready for review June 15, 2026 22:28
@jared-outpost

jared-outpost Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor Author

all CI checks passed (Build, Dependency Review, Secret Scan, Docs Preview, Warden, Semgrep) — marked ready for review. self-review found no issues; the change is a single-file fix that mirrors the existing serve command pattern.

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.

doesn't surface trace events inline

0 participants