Skip to content

chore(cli): migrate dashboard to playwright protocol#40143

Open
Skn0tt wants to merge 2 commits intomicrosoft:mainfrom
Skn0tt:dashboard-pw-client
Open

chore(cli): migrate dashboard to playwright protocol#40143
Skn0tt wants to merge 2 commits intomicrosoft:mainfrom
Skn0tt:dashboard-pw-client

Conversation

@Skn0tt
Copy link
Copy Markdown
Member

@Skn0tt Skn0tt commented Apr 10, 2026

No description provided.

@Skn0tt Skn0tt requested a review from dgozman April 10, 2026 09:39
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this called cli.ts?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

renamed it to dashboardBundle.ts to align with our naming

Comment thread packages/playwright-core/src/serverRegistry.ts Outdated
Comment thread packages/utils/httpServer.ts Outdated
Comment thread packages/playwright-core/src/tools/dashboard/DEPS.list Outdated
Comment thread utils/build/build.js Outdated
entryPoints: [
filePath('packages/playwright-client/src/cli.ts'),
],
outfile: filePath('packages/playwright-core/lib/clientBundle.js'),
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't we need an entry in package.json to be able to require this?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, because we don't require it. We fs.readFile it.

Comment thread packages/playwright-client/src/cli.ts Outdated
onclose?: (cause?: string) => void;
}

// this entrypoint is used between dashboard and playwright-cli.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • I don't think this comment is too useful. Better explain this is the entry point to the client bundle.
  • Why not use playwright.chromium.connect()?
  • Should we also pass a platform instance?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated the comment. we can't use playwright.chromium.connect because it won't use the browser's websocket impl. I don't think we should pass the platform instance so it's easier to maintain cross-version compatibility

@Skn0tt Skn0tt force-pushed the dashboard-pw-client branch from fbd4c64 to 7b2512b Compare April 13, 2026 11:31
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@Skn0tt Skn0tt force-pushed the dashboard-pw-client branch from 9a64e0c to 981d904 Compare April 14, 2026 06:39
@Skn0tt Skn0tt requested a review from dgozman April 14, 2026 06:39
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions
Copy link
Copy Markdown
Contributor

Test results for "MCP"

1 failed
❌ [chrome] › mcp/dashboard.spec.ts:48 › should show current workspace sessions first @mcp-windows-latest

5986 passed, 916 skipped


Merge workflow run.

@github-actions
Copy link
Copy Markdown
Contributor

Test results for "tests 1"

10 flaky ⚠️ [installation tests] › skip-browser-download.spec.ts:20 › should skip browser installs `@package-installations-ubuntu-latest`
⚠️ [chromium-library] › library/popup.spec.ts:261 › should not throw when click closes popup `@ubuntu-22.04-chromium-tip-of-tree`
⚠️ [chromium-library] › library/popup.spec.ts:261 › should not throw when click closes popup `@chromium-ubuntu-22.04-node20`
⚠️ [chromium-library] › library/video.spec.ts:724 › screencast › should work with video+trace `@chromium-ubuntu-22.04-node20`
⚠️ [chromium-page] › page/page-request-continue.spec.ts:754 › propagate headers cross origin redirect after interception `@chromium-ubuntu-22.04-node20`
⚠️ [firefox-library] › library/browsertype-connect.spec.ts:776 › launchServer › should upload a folder `@firefox-ubuntu-22.04-node20`
⚠️ [firefox-library] › library/inspector/cli-codegen-1.spec.ts:1080 › cli codegen › should not throw csp directive violation errors `@firefox-ubuntu-22.04-node20`
⚠️ [firefox-library] › library/inspector/cli-codegen-3.spec.ts:224 › cli codegen › should generate frame locators (4) `@firefox-ubuntu-22.04-node20`
⚠️ [firefox-page] › page/jshandle-to-string.spec.ts:59 › should work with different subtypes @smoke `@firefox-ubuntu-22.04-node20`
⚠️ [playwright-test] › ui-mode-trace.spec.ts:384 › should reveal errors in the sourcetab `@windows-latest-node20`

39173 passed, 847 skipped


Merge workflow run.

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.

2 participants