Hi there. I have the latest python, selenium and chrome versions installed on my Mac. I created a script in python with selenium and headless setup, and it ran successfully locally.
When I upload the file to PythonAnywhere and ran the code, the website that I'm interacting with is not working properly. I got the result: <html><head><title>Unavailable</title></head><body>Unavailable</body></html>.
My headless setup is: chrome_options = webdriver.ChromeOptions() chrome_options.add_argument("--no-sandbox") chrome_options.add_argument("--headless=new") chrome_options.add_argument("--disable-gpu") chrome_options.add_argument("user-agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.88 Safari/537.36") chrome_options.add_argument('--lang=pt_BR') chrome_options.add_argument('--414,900') driver = webdriver.Chrome(options=chrome_options)
How can I update chrome and chromedriver on PythonAnywhere?