Skip to content

Comments

feat(devtools): chrome devtools + pick locator#39256

Merged
Skn0tt merged 5 commits intomicrosoft:mainfrom
Skn0tt:chrome-devtools
Feb 13, 2026
Merged

feat(devtools): chrome devtools + pick locator#39256
Skn0tt merged 5 commits intomicrosoft:mainfrom
Skn0tt:chrome-devtools

Conversation

@Skn0tt
Copy link
Member

@Skn0tt Skn0tt commented Feb 13, 2026

No description provided.

@github-actions

This comment has been minimized.

frame: { data: string; viewportWidth: number; viewportHeight: number };
tabs: { tabs: Tab[] };
elementPicked: { selector: string };
recorderModeChanged: { picking: boolean };
Copy link
Contributor

Choose a reason for hiding this comment

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

Why do we need this event, when picking is explicitly controlled through pickLocator()/cancelPickLocator() methods from the other side?

I'd understand this one if we can click in the page to change the mode, e.g. start recording or something. But then it would have the mode argument, not picking.

if (browserConfig.browserName === 'chromium') {
(browserConfig.launchOptions as any).cdpPort = await findFreePort();
(browserConfig.launchOptions as any).args ??= [];
(browserConfig.launchOptions as any).args.push('--remote-allow-origins=*'); // TODO: make this secure by allowing only our origins. maybe proxy instead?
Copy link
Contributor

Choose a reason for hiding this comment

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

  • Let's figure this out.
  • It would be great for things to work without forcing --remote-debugging-port.

}, [captured]);

React.useEffect(() => {
pickingRef.current = picking;
Copy link
Contributor

Choose a reason for hiding this comment

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

I can't say I understand the relationship between picking and pickingRef...

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

}

private async _initializeRawSession(pageId: string) {
const page = this._context.pages().find(p => p.guid === pageId);
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this change upon selectTab()? I am not sure how the UI works, perhaps we need to reopen DevTools with a different ws url?

Copy link
Member Author

@Skn0tt Skn0tt Feb 13, 2026

Choose a reason for hiding this comment

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

the UI reloads the devtools iframe upon switching tabs, everything's fine.

@github-actions

This comment has been minimized.

@Skn0tt Skn0tt requested a review from dgozman February 13, 2026 12:39
@github-actions

This comment has been minimized.

@Skn0tt Skn0tt merged commit e078523 into microsoft:main Feb 13, 2026
30 of 33 checks passed
@github-actions
Copy link
Contributor

Test results for "tests 1"

23 failed
❌ [playwright-test] › aria-snapshot-file.spec.ts:225 › should respect config.expect.toMatchAriaSnapshot.pathTemplate @macos-latest-node20
❌ [playwright-test] › esm.spec.ts:545 › should resolve .js import to .tsx file in ESM mode for components @macos-latest-node20
❌ [playwright-test] › expect-to-pass.spec.ts:63 › should not fail when used with web-first assertion @macos-latest-node20
❌ [playwright-test] › global-setup.spec.ts:313 › globalSetup should work for auth @macos-latest-node20
❌ [playwright-test] › loader.spec.ts:306 › should filter stack trace for web-first assertions @macos-latest-node20
❌ [playwright-test] › max-failures.spec.ts:67 › max-failures should work with retries @macos-latest-node20
❌ [playwright-test] › playwright.artifacts.spec.ts:367 › should work with trace: on-all-retries @macos-latest-node20
❌ [playwright-test] › playwright.artifacts.spec.ts:403 › should work with trace: retain-on-first-failure @macos-latest-node20
❌ [playwright-test] › playwright.ct-build.spec.ts:354 › should not crash when cached component test file is deleted @macos-latest-node20
❌ [playwright-test] › playwright.reuse.spec.ts:431 › should cancel pending operations upon reuse @macos-latest-node20
❌ [playwright-test] › playwright.reuse.spec.ts:455 › should reset tracing @macos-latest-node20
❌ [playwright-test] › playwright.spec.ts:779 › should save trace in two APIRequestContexts @macos-latest-node20
❌ [playwright-test] › playwright.trace.spec.ts:137 › should not throw with trace: on-first-retry and two retries in the same worker @macos-latest-node20
❌ [playwright-test] › playwright.trace.spec.ts:389 › trace:on-all-retries should not create trace zip artifact if page test passed @macos-latest-node20
❌ [playwright-test] › playwright.trace.spec.ts:389 › trace:retain-on-first-failure should not create trace zip artifact if page test passed @macos-latest-node20
❌ [playwright-test] › playwright.trace.spec.ts:436 › trace:retain-on-failure should create trace if context is closed before failure in the test @macos-latest-node20
❌ [playwright-test] › reporter-base.spec.ts:259 › created › should print if globalTimeout is reached @macos-latest-node20
❌ [playwright-test] › reporter-junit.spec.ts:310 › created › should render existing attachments, but not missing ones @macos-latest-node20
❌ [playwright-test] › reporter-junit.spec.ts:337 › created › should render attachment paths relative to report file when report file name is specified @macos-latest-node20
❌ [playwright-test] › reporter-line.spec.ts:193 › created › should show error context with relative path @macos-latest-node20
❌ [playwright-test] › reporter-line.spec.ts:193 › merged › should show error context with relative path @macos-latest-node20
❌ [playwright-test] › snapshot-path-template.spec.ts:50 › tokens should expand property @macos-latest-node20
❌ [playwright-test] › ui-mode-test-network-tab.spec.ts:371 › should not preserve selection across test runs @macos-latest-node20

4 flaky ⚠️ [chromium-library] › library/inspector/recorder-api.spec.ts:120 › should type `@chromium-ubuntu-22.04-node24`
⚠️ [chromium-page] › page/page-request-continue.spec.ts:754 › propagate headers cross origin redirect after interception `@chromium-ubuntu-22.04-node24`
⚠️ [firefox-library] › library/beforeunload.spec.ts:188 › does not get stalled by beforeUnload `@firefox-ubuntu-22.04-node20`
⚠️ [firefox-library] › library/inspector/cli-codegen-1.spec.ts:1082 › cli codegen › should not throw csp directive violation errors `@firefox-ubuntu-22.04-node20`

38517 passed, 843 skipped


Merge workflow run.

@github-actions
Copy link
Contributor

Test results for "MCP"

1 failed
❌ [chrome] › mcp/cli-save-as.spec.ts:19 › screenshot @mcp-macos-15

4804 passed, 135 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