Reputation: 327
I am trying to run Selenium on Google App Engine. I have seen a lot of comments from years ago saying that you can't. The I found this link saying that headless Chrome is now available on GAE. The post has been written after the other comments that said that you can't use selenium on GAE so I gave it a try.
from selenium import webdriver
browser = webdriver.Chrome()
After deploying the code to gae I got this error:
ages/selenium/webdriver/common/service.py", line 76, in start stdin=PIPE) File "/opt/python3.7/lib/
python3.7/subprocess.py", line 775, in __init__ restore_signals, start_new_session) File "/opt/pyth
on3.7/lib/python3.7/subprocess.py", line 1522, in _execute_child raise child_exception_type(errno_num,
err_msg, err_filename) FileNotFoundError: [Errno 2] No such file or directory: 'chromedriver': 'chromedriver'
Am I doing something wrong or did I misunderstand the linked post?
Upvotes: 1
Views: 1099
Reputation: 5276
The link you provided is for the Node.js runtime. It might not be available in python yet.
I was able to get it working in python on App Engine Flex by doing the following
Python Headless Browser for GAE
For your specific error I had to edit the docker file to download the webdriver
Upvotes: 1