Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Error: EPERM: operation not permitted, unlink "..../CrashpadMetrics-active.pma" #4780

Closed
meotimdihia opened this issue Dec 20, 2020 · 8 comments · Fixed by #5539
Closed
Assignees

Comments

@meotimdihia
Copy link

meotimdihia commented Dec 20, 2020

Context:

  • Playwright Version: ^v1.6.2
    System:
    OS: Windows 10 10.0.19041
    Memory: 5.71 GB / 15.92 GB
    Binaries:
    Node: 12.14.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.5 - ~.yarn\bin\yarn.CMD
    npm: 6.14.10 - C:\Program Files\nodejs\npm.CMD
    Languages:
    Bash: 4.4.23 - C:\Program Files\git\usr\bin\bash.EXE

Code Snippet

let browser
;(async () => {
  try {
    const { chromium } = require("playwright")
    browser = await chromium.launch()
    const context = await browser.newContext()
    const page = await context.newPage()
    await page.goto("https://exampsas12le.com")
  } catch (e) {
//    await new Promise(resolve => setTimeout(resolve, 1000))  // The bug won't happen if I uncomment this line
    await browser.close()
  }
})()

Describe the bug
The code works fine in headless: false mode but the bug appear in headless mode.

$ node dist/src/examples/test
[Error: EPERM: operation not permitted, unlink 'C:\Users\meoti\AppData\Local\Temp\playwright_chromiumdev_profile-CVW7lo\CrashpadMetrics-active.pma'] {
  errno: -4048,
  code: 'EPERM',
  syscall: 'unlink',
  path: 'C:\\Users\\meoti\\AppData\\Local\\Temp\\playwright_chromiumdev_profile-CVW7lo\\CrashpadMetrics-active.pma'
}

WindowsTerminal_2020-12-20_14-55-19

@JoelEinbinder
Copy link
Contributor

Thanks for the report. Does this happen on any url?

@meotimdihia
Copy link
Author

meotimdihia commented Dec 22, 2020 via email

@pavelfeldman
Copy link
Member

@dgozman could it be that you fixed it?

@dgozman dgozman assigned aslushnikov and unassigned dgozman Feb 4, 2021
@aslushnikov
Copy link
Collaborator

aslushnikov commented Feb 19, 2021

Crash reporter has been disabled in Firefox in #5514. The new version will be released in v1.9.0, and hopefully we won't see this issue ever again

aslushnikov added a commit to aslushnikov/playwright that referenced this issue Feb 20, 2021
This roll includes:
- fix for Windows start
- crashpad disabling
- refreshed Firefox Beta @ Feb 19, 2021

Fixes microsoft#4660, fixes microsoft#4780
aslushnikov added a commit that referenced this issue Feb 21, 2021
This roll includes:
- fix for Windows start
- crashpad disabling
- refreshed Firefox Beta @ Feb 19, 2021

Fixes #4660, fixes #4780
@meotimdihia
Copy link
Author

@aslushnikov: the bug is remaining for playwright 1.9.1

@MkrV
Copy link

MkrV commented Mar 6, 2021

I have the same issue, even at headful mode.
playwright-python 1.9.1, Windows 10.

because of it Chromium(chrome.exe) doesn't close correctly, and very soon start consuming 100% CPU.
As a temporary solution I close all Chromiums via CMD in Admin mode:
wmic process where ExecutablePath='C:\Users\User\AppData\Local\ms-playwright\chromium-854489\chrome-win\chrome.exe' delete

@mxschmitt
Copy link
Member

Folding into #6123

@mxschmitt
Copy link
Member

Closing since #6123 was closed and https://chromium-review.googlesource.com/c/chromium/src/+/2999433 was merged.

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 a pull request may close this issue.

7 participants