当前位置: 首页 > 知识库问答 >
问题:

Selenium网络驱动程序无法启动Firefox 26

夏英发
2023-03-14

在升级到firefox 26.0之前,我在firefox的早期版本中使用了selenium 2.35。以前我的测试运行得很好,但现在我得到了以下错误。

 org.openqa.selenium.firefox.NotConnectedException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output:
*** LOG addons.manager: Application has been upgraded
*** LOG addons.xpi: startup
*** LOG addons.xpi: Skipping unavailable install location app-system-local
*** LOG addons.xpi: Skipping unavailable install location app-system-share
*** LOG addons.xpi: Ignoring file entry whose name is not a valid add-on ID: C:\Users\VISHAL~1.SIN\AppData\Local\Temp\anonymous4627406201097696285webdriver-profile\extensions\webdriver-staging
*** LOG addons.xpi: checkForChanges
*** LOG addons.xpi-utils: Opening XPI database C:\Users\VISHAL~1.SIN\AppData\Local\Temp\anonymous4627406201097696285webdriver-profile\extensions.json
*** LOG addons.xpi: New add-on fxdriver@googlecode.com installed in app-profile
*** Blocklist::_loadBlocklistFromFile: blocklist is disabled
*** LOG addons.xpi-utils: Make addon app-profile:fxdriver@googlecode.com visible
*** LOG DeferredSave/extensions.json: Save changes
*** LOG DeferredSave/extensions.json: Save changes
*** LOG addons.xpi: New add-on {9F17B1A2-7317-49ef-BCB7-7BB47BDE10F8} installed in winreg-app-user
*** LOG addons.xpi-utils: Make addon winreg-app-user:{9F17B1A2-7317-49ef-BCB7-7BB47BDE10F8} visible
*** LOG DeferredSave/extensions.json: Save changes
*** LOG DeferredSave/extensions.json: Save changes
*** LOG addons.xpi: New add-on {972ce4c6-7e08-4474-a285-3208198ce6fd} installed in app-global
*** LOG addons.xpi-utils: Make addon app-global:{972ce4c6-7e08-4474-a285-3208198ce6fd} visible
*** LOG DeferredSave/extensions.json: Save changes
*** LOG DeferredSave/extensions.json: Save changes
*** LOG addons.xpi: New add-on {9F17B1A2-7317-49ef-BCB7-7BB47BDE10F8} installed in winreg-app-global
*** LOG DeferredSave/extensions.json: Save changes
*** LOG addons.xpi: New add-on mgsusageagent@managesoft.com installed in winreg-app-global
*** LOG addons.xpi-utils: Make addon winreg-app-global:mgsusageagent@managesoft.com visible
*** LOG DeferredSave/extensions.json: Save changes
*** LOG DeferredSave/extensions.json: Save changes
*** LOG addons.xpi: Updating database with changes to installed add-ons
*** LOG addons.xpi-utils: Updating add-on states
*** LOG addons.xpi-utils: Writing add-ons list
*** LOG DeferredSave/extensions.json: Starting timer
*** LOG DeferredSave/extensions.json: Starting write
*** LOG DeferredSave/extensions.json: Write succeeded
*** LOG addons.xpi-utils: XPI Database saved, setting schema version preference to 15
*** LOG addons.manager: shutdown
*** LOG addons.xpi: shutdown
*** LOG addons.xpi-utils: shutdown
*** LOG addons.xpi: Notifying XPI shutdown observers
*** LOG addons.manager: Async provider shutdown done
*** LOG addons.xpi: startup
*** LOG addons.xpi: Skipping unavailable install location app-system-local
*** LOG addons.xpi: Skipping unavailable install location app-system-share
*** LOG addons.xpi: Ignoring file entry whose name is not a valid add-on ID: C:\Users\VISHAL~1.SIN\AppData\Local\Temp\anonymous4627406201097696285webdriver-profile\extensions\webdriver-staging
*** LOG addons.xpi: checkForChanges
*** LOG addons.xpi: No changes found
JavaScript error: chrome://browser/content/urlbarBindings.xml, line 654: aUrl is undefined

我试图降级火狐的版本,但无法从mozilla网站获得任何以前的版本。

我还尝试了所有的selenium版本2.36,2.37,2.38,2.39但似乎没有一个与火狐26.0兼容。一旦我试图用2.36到2.39替换selenium 2.35,代码中就会出现错误。当我再次用2.35替换时,这些错误就消失了。

有人能帮我看看Selenium和Firefox的兼容版本吗?

共有3个答案

魏威
2023-03-14

火狐26与工作与硒2.39

<seleniumVersion>2.39.0</seleniumVersion>
耿锦
2023-03-14

原因是:

无法连接到端口7055上的主机127.0.0.1

错误是Selenium Server的版本不知道如何使用较新版本的Firefox。您需要下载支持较新版本Firefox的较新版本Selenium Server。

请参阅:无法连接到GitHub端口7055上的主机127.0.0.1。

丁曦
2023-03-14

您可以使用2.0版本的selenium。XX但我们只能使用firefox25或firefox 14.01至17,这是唯一的限制。XX

 类似资料: