

'', 'application/octet-stream')Įxecutable_path=gecko_dir, firefox_profile=profile)ĭriver. com Run command for Chrome to open a website.

My code is just like: profile = webdriver.FirefoxProfile() I 39 m using Unix without a shell and Firefox has followed close behind. I think maybe it's a bug for firefox_profile. More, i found if i don't set firefox_profile the first way to run my code also working. All above tests have setted firefox_profile. The problem is: it doesn't work for me if i am using python file.py to run my code, but work if I setup the driver in python console, here not work is to say it just close my url, but the firefox browser not exit.

And I know driver.close() is to close current window and driver.quit() will close all windows and exit browser. After the work done, i need to close browser(I must use firefox). I'm using python selenium do some automatic work.
