简体   繁体   English

错误-消息:无法加载配置文件。 个人资料目录…使用Firefox进行Selenium Web抓取

[英]ERROR - Message: Can't load the profile. Profile Dir… Selenium Web Scraping with Firefox

I am running a web scraper using selenium and from time to time, I 我正在使用硒运行网络刮板,我有时会

ERROR - Message: Can't load the profile. Profile Dir: %s If you specified a log_file in the FirefoxBinary constructor, check it for details.

I know it means selenium can't open a session but how do I resolve this? 我知道这意味着Selenium无法打开会话,但是我该如何解决呢? Should I put in a retry mechanism with an exponential backoff? 我应该采用具有指数补偿的重试机制吗? Is it a bug in selenium? 这是硒中的错误吗?

I don't know but any help in resolving this issue would be much appreciated. 我不知道,但是对解决此问题的任何帮助将不胜感激。 Thanks. 谢谢。

$ brew install geckodriver
$ pip install -U selenium

firefox_capabilities = DesiredCapabilities.FIREFOX
firefox_capabilities['marionette'] = True

driver = webdriver.Firefox(capabilities=firefox_capabilities)
driver.get('http://example.com')

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 selenium.common.exceptions.WebDriverException:消息:“无法加载配置文件。配置文件目录: - selenium.common.exceptions.WebDriverException: Message: "Can't load the profile. Profile Dir: python selenium webdriver问题(selenium.common.exceptions.WebDriverException:消息:“无法加载配置文件。配置文件目录:) - python selenium webdriver issue ( selenium.common.exceptions.WebDriverException: Message: "Can't load the profile. Profile Dir: ) WebDriverException:消息:无法加载配置文件。 不知道发生了什么 - WebDriverException: Message: Can't load the profile. At a loss as to what is happening WebDriverException:消息:无法加载配置文件。 可能的 Firefox 版本不匹配。 对于 Firefox 48+ 和 Selenium,您必须使用 GeckoDriver - WebDriverException: Message: Can't load the profile. Possible firefox version mismatch. You must use GeckoDriver instead for Firefox 48+with Selenium Selenium Webdriver错误:“无法加载配置文件” - Selenium Webdriver error: “Can't load the profile” Selenium (Python) (Firefox) 无法写入 Firefox 配置文件。 权限被拒绝(操作系统错误 13) - Selenium (Python) (Firefox) is unable to write Firefox profile. Permission denied (os error 13) Python:Selenium Firefox Webdriver失败并显示错误:'无法加载配置文件... WARN addons.xpi ...“ - Python: Selenium Firefox Webdriver failing with error: 'Can't load the profile…WARN addons.xpi…" selenium.common.exceptions.WebDriverException:消息:无法加载配置文件 - selenium.common.exceptions.WebDriverException: Message: Can't load the profile WebDriverException:无法在selenium python脚本中加载配置文件错误 - WebDriverException:can't load profile error in selenium python script 在python selenium中加载Firefox的配置文件 - Load a profile of Firefox in python selenium
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM