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] ffmpeg dependency check fails on Linux #3845

Closed
anthonychu opened this issue Sep 11, 2020 · 2 comments · Fixed by #3882
Closed

[BUG] ffmpeg dependency check fails on Linux #3845

anthonychu opened this issue Sep 11, 2020 · 2 comments · Fixed by #3882

Comments

@anthonychu
Copy link
Member

Context:

  • Playwright Version: 1.4.0
  • Operating System: Linux (Azure Functions Linux Consumption plan)
  • Node.js version: 12.x
  • Browser: Chromium
  • Extra: [any specific details about your environment]

The new ffmpeg dependency check is a breaking change on Linux because it now expects ffmpeg in the path. Is it possible to only run the check when video recording is activated?

Code Snippet

This app, with the playwright version bumped to 1.4.0. https://github.com/anthonychu/functions-headless-chromium/tree/main/playwright

Exception: Error: browserType.launch: Host system is missing dependencies!

  Install missing packages with:
      sudo apt-get install ffmpeg


Note: use DEBUG=pw:api environment variable and rerun to capture Playwright logs.
Stack: browserType.launch: Host system is missing dependencies!

  Install missing packages with:
      sudo apt-get install ffmpeg


Note: use DEBUG=pw:api environment variable and rerun to capture Playwright logs.
    at BrowserType._wrapApiCall (/home/site/wwwroot/node_modules/playwright-chromium/lib/client/channelOwner.js:76:15)
    at BrowserType.launch (/home/site/wwwroot/node_modules/playwright-chromium/lib/client/browserType.js:48:21)
    at module.exports (/home/site/wwwroot/screenshot/index.js:5:37)
    at WorkerChannel.invocationRequest (/azure-functions-host/workers/node/worker-bundle.js:18518:26)
    at ClientDuplexStream.<anonymous> (/azure-functions-host/workers/node/worker-bundle.js:18324:30)
    at ClientDuplexStream.emit (events.js:315:20)
    at addChunk (_stream_readable.js:295:12)
    at readableAddChunk (_stream_readable.js:271:9)
    at ClientDuplexStream.Readable.push (_stream_readable.js:212:10)
    at Object.onReceiveMessage (/azure-functions-host/workers/node/worker-bundle.js:22785:19)

@arjun27

@arjunattam
Copy link
Contributor

@yury-s, @aslushnikov - I believe this issue would be fixed if we bundled ffmpeg for Linux as well with the NPM package (as we have for Windows/macOS). Is it possible to do that? I'm a bit hesitant to make ffmpeg an optional dependency since screencast is a highly requested user feature.

@anthonychu
Copy link
Member Author

Agreed. Bundling would be a better solution.

anthonychu added a commit to anthonychu/functions-headless-chromium that referenced this issue Sep 11, 2020
aslushnikov added a commit that referenced this issue Sep 15, 2020
This patch bakes ffmpeg-linux r1001 into our NPM package.

This increases NPM package size from 4.2MB to 6.7MB.

Fixes #3845
aslushnikov added a commit to aslushnikov/playwright that referenced this issue Sep 15, 2020
aslushnikov added a commit to aslushnikov/playwright that referenced this issue Sep 15, 2020
aslushnikov added a commit that referenced this issue Sep 16, 2020
ianschmitz added a commit to vertigis/vertigis-web-sdk that referenced this issue Sep 17, 2020
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.

3 participants