Loofer
Loofer

Reputation: 6963

Selenium has an IPv6 issue when using firefoxdriver

I am trying to use Selenium to drive some web tests in Firefox, however when I do this

FirefoxDriver _driver = new FirefoxDriver();

I get this exception

An address incompatible with the requested protocol was used [::1]:7055

This appears to be some sort of IPv6 vs IPv4 issue that selenium is not going to fix. however I need to work around it. Disabling IPv6 on my Ethernet makes no difference. what else can I try?

Cheers

Upvotes: 5

Views: 1406

Answers (1)

Rattle
Rattle

Reputation: 2553

I'm making a few assumptions here, but this looks like an issue I had using Selenium on Windows when connecting to a URL on localhost. The issue may be due to localhost resolving as ::1 instead of 127.0.0.1 on Windows 2008.

If that is the case add the line 127.0.0.1 localhost into C:\Windows\System32\drivers\etc\hosts

Upvotes: 2

Related Questions