Python Forum

Full Version: Error when trying to use Selenium
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pretty sure it has something to do with the run permissions of it but I don't know how to fix it. I'm very new to Python so please dumb down your reply as much as possible. Thank you in advance.

+ I'm using PyCharm and ran it as administrator, still doesn't work

>>> browser = webdriver.Chrome('C:\SeleniumDrivers')
Traceback (most recent call last):
  File "C:\Users\Mario\PycharmProjects\py1\venv\lib\site-packages\selenium\webdriver\common\", line 76, in start
  File "C:\Users\Mario\AppData\Local\Programs\Python\Python37-32\lib\", line 775, in __init__
    restore_signals, start_new_session)
  File "C:\Users\Mario\AppData\Local\Programs\Python\Python37-32\lib\", line 1178, in _execute_child
PermissionError: [WinError 5] Access is denied
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "C:\Users\Mario\PycharmProjects\py1\venv\lib\site-packages\selenium\webdriver\chrome\", line 73, in __init__
  File "C:\Users\Mario\PycharmProjects\py1\venv\lib\site-packages\selenium\webdriver\common\", line 88, in start
    os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'SeleniumDrivers' executable may have wrong permissions. Please see
Fixed it nvm.

I didnt have "\chromedriver.exe" at the end of my thing. Also ran pycharm as admin