Python Forum
Selenium error with ebdriver (geckodriver)
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Selenium error with ebdriver (geckodriver)
#1
Hi, All!

I am using this code:

Quote:from selenium import webdriver
nav = webdriver.Firefox()

But, I am getting the following error:

Quote:/home/martinelli/PycharmProjects/ESAB/venv/bin/python /home/martinelli/PycharmProjects/ESAB/LogaSGE.py
Traceback (most recent call last):
File "/home/martinelli/PycharmProjects/ESAB/venv/lib/python3.7/site-packages/selenium/webdriver/common/service.py", line 76, in start
stdin=PIPE)
File "/usr/lib/python3.7/subprocess.py", line 775, in __init__
restore_signals, start_new_session)
File "/usr/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: 'geckodriver': 'geckodriver'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/martinelli/PycharmProjects/ESAB/LogaSGE.py", line 5, in <module>
nav = webdriver.Firefox()
File "/home/martinelli/PycharmProjects/ESAB/venv/lib/python3.7/site-packages/selenium/webdriver/firefox/webdriver.py", line 164, in __init__
self.service.start()
File "/home/martinelli/PycharmProjects/ESAB/venv/lib/python3.7/site-packages/selenium/webdriver/common/service.py", line 83, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'geckodriver' executable needs to be in PATH.

Process finished with exit code 1

I have installed PYCharm Community 2019.2.2. It is Python 3.7. I am using Debian 10 (Buster). I have changed the permission from the / with rmx to all users, directories and files, in case, "geckodriver". Also, I have inserted "geckodriver" and its PATH on the enviromnent PATH, and, also, to the "Interpreter Paths".

But it keeps giving this error.

Has Anyone any ideia what I can do?
Reply


Messages In This Thread
Selenium error with ebdriver (geckodriver) - by Martinelli - Sep-22-2019, 09:34 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Selenium weird error julio2000 0 1,739 Feb-23-2020, 01:24 PM
Last Post: julio2000
  Selenium webdriver error WiPi 4 12,398 Feb-09-2020, 11:38 AM
Last Post: WiPi
  error when running headless selenium julio2000 2 4,707 Feb-01-2020, 12:41 PM
Last Post: julio2000
  Error clicking button with selenium julio2000 4 5,462 Jan-06-2020, 10:59 AM
Last Post: julio2000
  Python Selenium .click() Loads Error - Works Manually.- Events not Triggered NSearch 24 12,337 Aug-14-2019, 02:23 PM
Last Post: NSearch
  Error when trying to use Selenium ejected 1 5,287 Mar-26-2019, 04:53 AM
Last Post: ejected
  Instagramlogin Error (Selenium) julian_veit 0 2,698 Jan-26-2019, 02:40 PM
Last Post: julian_veit
  selenium error : evilcode1 7 5,326 Nov-12-2018, 01:08 PM
Last Post: snippsat
  Getting error when accessing elements in a modal window of an webpage using selenium sumandas89 3 8,825 Jul-13-2018, 10:44 AM
Last Post: mlieqo
  Python 3/selenium - nontype error water_fox 2 12,054 Jun-28-2018, 08:19 PM
Last Post: Sudhakar

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020