Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Selenium Webdriver(Python): Firefox gives Permission denied: 'geckodriver.log'

  • 06-10-2020 08:19PM
    #1
    Registered Users, Registered Users 2 Posts: 5,723 ✭✭✭


    So i keep getting this permissions error when initialising. Sounds simple enough, no permission to write wherever the directory is for the log.
     log_file = open(log_path, "a+") if log_path is not None and log_path != "" else None
    PermissionError: [Errno 13] Permission denied: 'geckodriver.log'
    

    So i tried doing chmod 777 on the directory and specifying it, hardcoding below at initializing stage

    if browser == 'firefox':
            return webdriver.Firefox(
                executable_FIREFOXDRIVER_PATH,
                log_path='./geckodriver.log')
    

    But still i get the error. Anyone seen before?


Comments

  • Registered Users, Registered Users 2 Posts: 7,157 ✭✭✭srsly78


    Need permission on parent folders as well, at least +x on all.


Advertisement