playwright
playwright copied to clipboard
[Bug]: New Chromium window flashes when clicking on Playwright icon in macOS dock (related to #9434)
Version
1.41.1
Steps to reproduce
When you click on the Playwright icon for UI Mode in the macOS dock, a new Chromium window will briefly open and then close.
This looks closely related to #9434 - my theory is the fix in #26877 attempts to close the window immediately after it opens, but sometimes this is not fast enough, which leads to the very distracting flashing shown in the video.
Pure speculation Taking a completely unqualified look at the Chromium source code, it seems that this function handles the click on the dock icon. There is a check to see if an existing window is open, but it excludes apps, which Playwright is launched as. Interestingly, apps created through the "Create shortcut" functionality in Chromium don't suffer from this flashing issue. Perhaps there is a solution there without changing anything upstream in Chromium?
https://github.com/microsoft/playwright/assets/103429299/6da05db5-8b06-476f-9a1a-4952ec91f3bb
Expected behavior
No flashing should happen when I click the Playwright icon in the macOS dock.
Actual behavior
Occasionally a new window briefly flashes on screen.
Additional context
No response
Environment
System:
OS: macOS 14.1.1
Memory: 49.66 MB / 32.00 GB
Binaries:
Node: 18.19.0 - ~/.nvm/versions/node/v18.19.0/bin/node
Yarn: 1.22.21 - /opt/homebrew/bin/yarn
npm: 10.2.3 - ~/.nvm/versions/node/v18.19.0/bin/npm
Languages:
Bash: 3.2.57 - /bin/bash
If you manage to make it work, we are open to a PR!
Closing as per above as non-actionable, but open to a PR from the reporter!