已经有了geckodriver.exe,但selenium出现以下错误,是因为系统中没有安装firefox:
selenium.common.exceptions.SessionNotCreatedException: Message: Expected browser binary location, but unable to find binary in default location, no ‘moz:firefoxOptions.binary’ capability provided, and no binary flag set on the command line
安装最新版本的firfox之后再打开就可以了。