-
Notifications
You must be signed in to change notification settings - Fork 906
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
[Feature] Playwright should be able to install browser binaries from poetry install (Python) #1322
Comments
Can you explain how you see this working with poetry (what commands the user would have to run to install playwright with browsers vs. without them)? Or do you want it to essentially run |
Hi, as playwright's strength is browser automation, so I think it should install browser as default. Installing all would be time and space consuming, so I think installing the one with the largest market share -which is chromium- would be a good choice for default. The adding method / syntax for browsers should follow optional dependencies: and I think it would be good to add browser dependencies automatically too, specially because the user may not know what are the dependencies and what kind of dependencies are there, what will not work without them BR, |
As of right now poetry add playwright does not work instead it throws and error. I am currently using poetry 1.1.13. How should I structure the commands to add playwright? |
@codejedi-ai What error do you have? |
Currently I use https://github.com/pyppeteer/pyppeteer within a python library to launch a headless chrome instance, do some "stuff" https://github.com/pyppeteer/pyppeteer currently will install a chrome instance on the first run. For example when testing a poetry project with 'tox'. As this is intended for a library and poetry will not provide the means to add a post install script to my lib is it possible to install a browser at runtime as with pyppeteer? Potential solutions to this problem are:
Thank you for your time :) |
Hi, |
+1 for @dil-gfischhof 's suggestion Using optional dependencies to install browsers would simplify CI, and help the dev workflow, for the project I'm currently working on. Would be great to see a resolution on this issue, either way, given the original creation date. |
+1 for the suggestion came across the issue while deploying a web scraping service, its clean if we can do this within poetry |
Playwright should be able to install browser binaries from poetry install (Python)
(Specially related to CI systems)
Hi Folks,
Two things to start my feature request with:
1.)
Poetry is practically the new way of Python package management
2.)
Installing project dependencies is practically the responsibility of the project (yes, the borders are flexible...)
So I have the following situation:
we have a project which needs in-browser testing, and API testing, perhaps someone will need other (performance etc) testing, which does not require browser.
Right now we use Poetry (Python) to install dependencies, it installs Playwright, but is not able to tell Playwright to install browsers binaries.
So now we have to setup our CI to install browser binaries, but the other CI jobs do not need that, so installing is just waste of time and space.
But it would be good to have only one type of test job in CI: install project dependencies, and start testing. And if the project needs browser then it should install it automatically.
BR,
George
The text was updated successfully, but these errors were encountered: