Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Port browser-integration-tests to span streaming

Đang mở
#24,131 1 bình luận 0 reaction 1 người được giao Xem trên GitHub

@msonnb đang làm issue này rồi.

Từ ngày 7/9/2026.

Đánh giá

Issue này chưa được đánh giá.

Mô tả

javascript Task

Port dev-packages/browser-integration-tests to span streaming. Span streaming is the default, so every suite that still pins traceLifecycle: 'static' covers behaviour we no longer ship.

Part of SDK-1425, one tracking issue per integration test package.

Scope

  • 315 traceLifecycle: 'static' pins across 299 files
  • 62 test.ts files call waitForTransactionRequest and need a real rewrite
  • 36 suites already have a -streamed twin, and 32 of those still sit next to the static original
  • The remaining ~226 pinned files never assert on a transaction, so they only need the pin removed

How to port a suite

  1. Remove the traceLifecycle: 'static' pin from the suite's init.js (and any subtest init).
  2. If a -streamed twin exists, fold it back: delete the static original and rename the twin to the base name. Do not keep both, or the coverage doubles and the two copies drift.
  3. Rewrite the assertions from transaction envelopes to span v2 using utils/spanUtils.ts:
    • waitForTransactionRequest becomes waitForStreamedSpan / waitForStreamedSpans
    • waitForStreamedSpanEnvelope gives the raw envelope when a test asserts on envelope headers
    • event.transaction becomes span.name
    • contexts.trace.op becomes the sentry.op attribute plus span.is_segment
    • contexts.trace.data['x'] becomes span.attributes['x'], which has the shape { value, type }
    • transaction_info.source becomes the sentry.segment.name.source attribute
  4. Streamed child spans arrive across several envelopes, so collect across envelopes wherever a test asserts on children of a segment span.

Watch for span names that become low cardinality under streaming: pageload, navigation, resource, http.client and web vitals. Those assertions change, not just the helper.

Keep static trace lifecycle coverage

Do not add a -static copy per suite. The profiling/traceLifecycleMode_* suites already exercise both lifecycles. Pick one tracing suite to keep on the static pin as a guard and say so in the PR.

Ngôn ngữ chính
TypeScript
Star
8.7k
Fork
1.9k
Merge trung bình
1 ngày 18 giờ
Pull request đã merge (30 ngày)
562

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của getsentry/sentry-javascript

Tất cả issue của getsentry/sentry-javascript

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.