[Feature]: Test runner captures and source-maps stacks that it never uses
I maintainer di solito rispondono entro 1 giorno
@microsoft-playwright-automation ci sta già lavorando.
Dal 24/11/2026.
- #44338 di @microsoft-playwright-automation — aperta
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 30/100
- Tipo di issue
- Refactoring
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- typescript
- Ambito
- performance, testing
Direzione di ricerca
Start in fixtureRunner.ts where _stepInfo.stack is set for built-in fixture steps, and in packages/isomorphic/manualPromise.ts at LongStandingScope._race(). Read closed PR #44326 for the already-tested implementation, then run the test-runner and manual-promise tests covering step metadata and close-error stacks. Done means built-in fixture steps carry stack: [], _race() reads .stack only when cloning a close error, and existing stack output stays unchanged.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem
Two hot paths in the worker format stacks that nobody reads:
- Built-in fixture steps (
page,context,request, and about 30 more) have no user location. InfixtureRunner.ts,_stepInfo.stackisundefined, sotestInfo._addStep()captures and source-maps a full raw stack, then filters it to 0 frames. This happens about 60 times per test. LongStandingScope._race()inpackages/isomorphic/manualPromise.tsreadsnew Error().stackon every call. The formatted stack is used only when the scope closes during the race.
Measurements
CPU profile of a 24-test suite, Apple Silicon, Chromium headless shell, 1 worker, median of 5 runs:
| Now | With both changes | |
|---|---|---|
| Worker CPU time | 995 ms | 806 ms (−19%) |
Proposed approach
- Give built-in fixture steps
stack: []. User fixtures keep their registration location. - In
_race(), keep theErrorand read.stackonly when it clones a close error. V8 records the frames when theErroris constructed, so close messages stay the same.
One difference: built-in fixture steps no longer report user locations injected by a custom Error.prepareStackTrace formatter. With the default formatter, they never had a location.
Already implemented and tested in #44326, which was closed only to file this issue first. Both are small, low-risk performance fixes. Reopening #44326 is the fastest path; it is ready for review.
- Lingua principale
- TypeScript
- Stelle
- 100k
- Fork
- 6.9k
- Merge medio
- 16h 18m
- PR unite (30g)
- 281
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di microsoft/playwright
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
microsoft/playwright#44340 ·
I maintainer di solito rispondono entro 1 giorno
-
[MCP]: page snapshots in .playwright-mcp/ are not git-ignored (.playwright-cli/ is, since #42318)Forse già presa @lazerg l’ha presa 2 giorni fa. Apertaagent-triage-done
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
microsoft/playwright#44289 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
[Feature]: expose per-project workers on FullProject for reportersForse già presa @microsoft-playwright-automation l’ha presa oggi. Apertaagent-triage-done
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
microsoft/playwright#44264 · 5 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
[Feature]: Skip PNG decode and diff when a screenshot matches its baseline byte for byteForse già presa @microsoft-playwright-automation l’ha presa oggi. Apertaagent-triage-done
Difficoltà 2/5 1-3 ore Idoneità per principianti 30/100
microsoft/playwright#44333 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug]: `.resolves.not` and `.rejects.not` pass when a promise settles the wrong wayForse già presa @microsoft-playwright-automation l’ha presa oggi. Apertaagent-triage-done
Difficoltà 3/5 Mezza giornata Idoneità per principianti 55/100
microsoft/playwright#44331 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di microsoft/playwright
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
primer/primitives#1426 ·
-
Sign-in-only setup dialog describes API-key verificationForse già presa @roboclaw-bot l’ha presa oggi. Apertaclawsweeper:fix-shape-clear clawsweeper:queueable-fix clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster no-stale P2
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 78/100
openclaw/openclaw#204323 · 1 commento · 1 reazione ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
virtue-initiative/virtue-initiative#953 ·
I maintainer di solito rispondono entro 1 giorno
-
needs-area-label
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
fumicode/bublys-org#261 ·
I maintainer di solito rispondono entro 12 giorni