Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

fix(dashboard): avoid stdout readiness race (#41901)

Simon Knottea219e66da41
diff --git a/packages/playwright-core/src/tools/dashboard/dashboardApp.ts b/packages/playwright-core/src/tools/dashboard/dashboardApp.ts
index 72d2c319dd..5faa603223 100644
--- a/packages/playwright-core/src/tools/dashboard/dashboardApp.ts
+++ b/packages/playwright-core/src/tools/dashboard/dashboardApp.ts
@@ -296,8 +296,6 @@ export async function openDashboardApp() {
stopSelfDestruct();
// eslint-disable-next-line no-console
console.log(`Dashboard is running pid=${acquired.daemonPid}`);
- // eslint-disable-next-line no-restricted-properties
- await new Promise(f => process.stdout.write('', f)); // Make sure stdout is flushed.
return;
}
const { server } = acquired;
@@ -319,8 +317,6 @@ export async function openDashboardApp() {
// eslint-disable-next-line no-console
console.log(`Dashboard is running pid=${process.pid}`);
}
- // eslint-disable-next-line no-restricted-properties
- await new Promise(f => process.stdout.write('', f)); // Make sure stdout is flushed.
} catch (error) {
// eslint-disable-next-line no-console
console.log(error);