Uh oh!
There was an error while loading. Please reload this page.
test(browser): Give profiling envelope tests headroom against CI timeouts - #22067
Conversation
…outs The profiling suites (manualMode, trace-lifecycle multiple-chunks and overlapping-spans) flake on CI. JS self-profiling plus chunk flush is slow and highly variable: locally, on an unloaded machine, a single run of the overlapping-spans test was observed anywhere from ~9s to ~25s. Two timeouts bite under CI load: - The Playwright per-test timeout (30s default). overlapping-spans and manualMode already use a 15s inner envelope-wait yet still flake, because the whole test brushes up against the 30s ceiling once the machine is loaded. - The inner `getMultipleSentryEnvelopeRequests` wait — multiple-chunks used only 5s, well under the observed spread. Mark the three heavy tests `sentryTest.slow()` (raising the per-test budget to 90s) and raise the inner envelope-wait timeouts to 20s. Both are pure ceilings — the wait resolves as soon as the expected chunks arrive, so there is no happy-path cost. No profile assertions are changed. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
A profiling run flaked on a sampled `removeEventListener` frame:
`expect(frame).toHaveProperty('abs_path')` failed because native/built-in browser
functions have no source location. The check exempted only a hardcoded list
(`fetch`, `setTimeout`, `clearTimeout`), but the sampler can capture any native
frame (removeEventListener, Promise callbacks, …).
Instead of chasing an ever-growing exemption list, only validate location
metadata for frames that actually carry a source path. User/source frames (which
the `expectedFunctionNames` checks still assert are present) keep full validation.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>mydea
commented
Jul 8, 2026
Follow-up: a run on this branch surfaced a second, distinct profiling flake — exactly the sampling-frame non-determinism I flagged in the description. The sampler captured a native Fixed in |
Uh oh!
There was an error while loading. Please reload this page.
The browser profiling suites (
manualMode, trace-lifecyclemultiple-chunksandoverlapping-spans) are a recurring source of flaky-CI reports across bundle variants.Root cause
JS self-profiling + chunk flush is slow and highly variable. Running the overlapping-spans test locally on an unloaded machine, a single iteration ranged from ~9s to ~25s. Two timeouts bite once CI is loaded:
getMultipleSentryEnvelopeRequestswait. multiple-chunks used only 5s, well under the observed spread.Fix
sentryTest.slow(), raising the per-test budget to 90s.Both are pure ceilings — the wait resolves as soon as the expected chunks arrive, so there's no happy-path cost and no profile assertion is changed (no coverage loss). Verified locally: the three suites pass, and overlapping-spans held green across 25 repeat-each iterations.
If any residual flakiness remains after this, it would point at sampling-profiler frame-capture non-determinism (which function names land in samples) rather than timeouts — a separate, narrower follow-up.
Fixes#22049
Fixes#22048
Fixes#21977
Fixes#22034
Fixes#22023
Fixes#21946
Fixes#21823
Fixes#21716
Fixes#21871
Fixes#21857
🤖 Generated with Claude Code