docker-maven-chrome
docker-maven-chrome copied to clipboard
Error: CreatePlatformSocket() failed: Address family not supported by protocol (97)
I'm getting this error when running my selenium tests in your container. The error appears right after the chromedriver is started:
Starting ChromeDriver 104.0.5112.79 (3cf3e8c8a07d104b9e1260c910efb8f383285dc5-refs/branch-heads/5112@{#1307}) on port 45363
Only local connections are allowed.
Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.
[ChromeDriver was started successfully.
1661868538.001][SEVERE]: CreatePlatformSocket() failed: Address family not supported by protocol (97)
[1661868538.649][SEVERE]: CreatePlatformSocket() failed: Address family not supported by protocol (97)
Then, all my tests fail with the same error:
org.openqa.selenium.TimeoutException:
timeout: Timed out receiving message from renderer: 29.799
(Session info: headless chrome=104.0.5112.101)
Build info: version: '4.4.0', revision: 'e5c75ed026a'
System info: host: 'runner-3vmhfkx-project-1343-concurrent-0', ip: '172.17.0.5', os.name: 'Linux', os.arch: 'amd64', os.version: '5.4.0-104-generic', java.version: '18.0.1.1'
Driver info: org.openqa.selenium.chrome.ChromeDriver
Command: [9c4f0f720cf9511d39901d6733b56ac1, get {url=redacted}]
selenide.url: https://mfe-individual-root-config-q.apps.pcfnp.fnni.com/individual/accounts
Capabilities {acceptInsecureCerts: true, browserName: chrome, browserVersion: 104.0.5112.101, chrome: {chromedriverVersion: 104.0.5112.79 (3cf3e8c8a07d..., userDataDir: /tmp/.com.google.Chrome.leKnwP}, goog:chromeOptions: {debuggerAddress: localhost:39713}, networkConnectionEnabled: false, pageLoadStrategy: normal, platformName: LINUX, proxy: Proxy(), se:cdp: ws://localhost:39713/devtoo..., se:cdpVersion: 104.0.5112.101, setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: accept, webauthn:extension:credBlob: true, webauthn:extension:largeBlob: true, webauthn:virtualAuthenticators: true}
selenide.baseUrl: redacted
Session ID: 9c4f0f720cf9511d39901d6733b56ac1
at uitestsindividual.HeaderFooter.HeaderMobileTests.setup(HeaderMobileTests.java:21)
I am running the docker container in a gitlab pipeline. So far, this specific error seems to be related to either the hosts file or IPv6 being disabled.
https://stackoverflow.com/a/48161643/9558744 https://bugs.chromium.org/p/chromium/issues/detail?id=700347
I was wondering if you could verify for me that the hosts file is configured correctly, and that the version of linux used supports IPv6. Thank you!