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

follow up question to issue #1017 how to run shell commands with activated env #1018

Open
AbhimanyuAryan opened this issue Dec 10, 2022 · 1 comment

Comments

@AbhimanyuAryan
Copy link

AbhimanyuAryan commented Dec 10, 2022

once I successfully install the playwright package with PyCall.jl

pyimport_conda("playwright", "playwright", "microsoft")

I need to run this shell command in that conda env to install web drivers for playwright python package. I don't know know how to call this from Playwright.jl package which is let's say

module Playwright
#...
#...
#...

function __init__()
		copy!(playwright, pyimport(.....)
        # here I need to run `playwright install` in that env
end

#...
#...

end

This is how the python output looks like in pytest-playwright conda env

┬─[abhi@Abhimanyus-MacBook-Air:~/m/e/p/l/p/s/playwright]─[19:58:57]
╰─>$ playwright install                                                                                    (pytest-playwright) 
Downloading Chromium 107.0.5304.18 (playwright build v1028) - 119.8 Mb [====================] 100% 0.0s 
Chromium 107.0.5304.18 (playwright build v1028) downloaded to /Users/abhi/Library/Caches/ms-playwright/chromium-1028
Downloading FFMPEG playwright build v1007 - 1 Mb [====================] 100% 0.0s 
FFMPEG playwright build v1007 downloaded to /Users/abhi/Library/Caches/ms-playwright/ffmpeg-1007
Downloading Firefox 105.0.1 (playwright build v1357) - 68.5 Mb [====================] 100% 0.0s 
Firefox 105.0.1 (playwright build v1357) downloaded to /Users/abhi/Library/Caches/ms-playwright/firefox-1357
Downloading Webkit 16.0 (playwright build v1724) - 53.9 Mb [====================] 100% 0.0s 
Webkit 16.0 (playwright build v1724) downloaded to /Users/abhi/Library/Caches/ms-playwright/webkit-1724
@AbhimanyuAryan AbhimanyuAryan changed the title follow up question to issues #1017 how to run shell commands with activated env follow up question to issue #1017 how to run shell commands with activated env Dec 10, 2022
@AbhimanyuAryan
Copy link
Author

continuing the conversation from here: #1010 (comment)

but yes @hhaensel I have gotten it to work on my windows machine. I am trying to understand how to install playwright drivers i.e. $playwright install from within inside of Julia while using the PyCall's conda environment. Because without the drivers the API won't work

page and all the playwright python API need to have drivers configured.

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

No branches or pull requests

1 participant