0
ローカルコンピュータでセレンを使用していますが、ソケットエラーが発生することがあります。これまでのところ、(Python)アプリケーションを再起動することは私のために働いています。セレンなしRC:接続が拒否されました
この原因は何ですか?
driver = webdriver.Firefox(firefox_profile=someProfile)
driver.get(someLink)
スタックトレースは:
Traceback (most recent call last):
File "/home/foo/.conda/envs/myenv3/lib/python3.5/site-packages/IPython/core/interactiveshell.py", line 2885, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "<ipython-input-2-cdc559ddfda1>", line 1, in <module>
driver.get(link)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/site-packages/selenium/webdriver/remote/webdriver.py", line 245, in get
self.execute(Command.GET, {'url': url})
File "/home/foo/.conda/envs/myenv3/lib/python3.5/site-packages/selenium/webdriver/remote/webdriver.py", line 231, in execute
response = self.command_executor.execute(driver_command, params)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/site-packages/selenium/webdriver/remote/remote_connection.py", line 395, in execute
return self._request(command_info[0], url, body=data)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/site-packages/selenium/webdriver/remote/remote_connection.py", line 425, in _request
self._conn.request(method, parsed_url.path, body, headers)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/http/client.py", line 1083, in request
self._send_request(method, url, body, headers)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/http/client.py", line 1128, in _send_request
self.endheaders(body)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/http/client.py", line 1079, in endheaders
self._send_output(message_body)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/http/client.py", line 911, in _send_output
self.send(msg)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/http/client.py", line 854, in send
self.connect()
File "/home/foo/.conda/envs/myenv3/lib/python3.5/http/client.py", line 826, in connect
(self.host,self.port), self.timeout, self.source_address)
File "/home/foo/.conda/envs/myenv3/lib/python3.5/socket.py", line 711, in create_connection
raise err
File "/home/foo/.conda/envs/myenv3/lib/python3.5/socket.py", line 702, in create_connection
sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused