G
G
GitiFela2021-08-17 21:32:33
Python
GitiFela, 2021-08-17 21:32:33

Selenium.common.exceptions.TimeoutException: Message: Connection refused (os error 111)?

Why does this code work on the local system. But on the vds server this error occurs? Everything you need to install, but still this is an error on the vds server.

from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.firefox.options import Options

from webdriver_manager.firefox import GeckoDriverManager

opts = Options()
opts.add_argument("--no-sandbox")
opts.add_argument("--disable-setuid-sandbox")
opts.add_argument("--headless")

driver = webdriver.Firefox(
      firefox_options=opts,
      executable_path=GeckoDriverManager().install()
)

driver.get("https://qna.habr.com")

driver.close()
driver.quit()

Answer the question

In order to leave comments, you need to log in

1 answer(s)
H
HemulGM, 2021-08-17
@HemulGM

And what, is it already difficult to translate the text of the error? Banned on translate.google.com?
No access to resource (Connection refused)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question