aerokube / selenoid

Selenium Hub successor running browsers within containers. Scalable, immutable, self hosted Selenium-Grid on any platform with single binary.
https://aerokube.com/selenoid/latest/
Apache License 2.0
2.57k stars 322 forks source link

Add se:cdpVersion to returned capabilities #1405

Open berkeroguz opened 7 months ago

berkeroguz commented 7 months ago

Hi everyone, I've an issue.

When i start to my test, I am facing below problem.

" Step failed
org.openqa.selenium.WebDriverException: disconnected: not connected to DevTools
  (failed to check if window was closed: disconnected: not connected to DevTools)
  (Session info: chrome=120.0.6099.129)
Build info: version: '4.17.0', revision: 'e52b1be057*'
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '14.3.1', java.version: '17.0.8.1'
Driver info: org.openqa.selenium.remote.RemoteWebDriver
Command: [7bbef36da4e72d49f16fee69cb7e1341, get {url=https://opqa.etasimacilik.com/uye-girisi}]
Capabilities {acceptInsecureCerts: false, browserName: chrome, browserVersion: 120.0.6099.129, chrome: {chromedriverVersion: 120.0.6099.109 (3419140ab66..., userDataDir: /tmp/.org.chromium.Chromium...}, fedcm:accounts: true, goog:chromeOptions: {debuggerAddress: localhost:34673}, networkConnectionEnabled: false, pageLoadStrategy: normal, platformName: linux, proxy: Proxy(), se:cdp: ws://localhost:4444/devtool..., setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:credBlob: true, webauthn:extension:largeBlob: true, webauthn:extension:minPinLength: true, webauthn:extension:prf: true, webauthn:virtualAuthenticators: true}
Session ID: 7bbef36da4e72d49f16fee69cb7e1341
    at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)
    at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
And Log on Chrome Container:

2024-02-19 16:28:40 Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.

2024-02-19 16:28:40 ChromeDriver was started successfully. 2024-02-19 16:28:43 X connection to :99 broken (explicit kill or server shutdown).

Versions:
ChromeDriver : 120
Image: 120 
Selenium Version: 4.15.0 , (and i tried 4.16.1 and 4.17.0 )
Jdk : 17.0

Actually, this problem has started after updated my mac :/
By the way, same project works correctly on remote server which is windows10.
How can i handle this? I tried upgrade or downgrade chrome version and also start selenoid with using cm file. (Normally I am using docker file.)
vania-pooh commented 7 months ago

@berkeroguz what is your Selenoid version?

vania-pooh commented 6 months ago

We may need to add se:cdpVersion support.

berkeroguz commented 6 months ago

Hi again, sorry for my late return.
Selenoid version : latest. I don't use a particular version.

aplanche commented 5 months ago

I experience exact the same issue. Is there a workaround known for now?

berkeroguz commented 5 months ago

I couldn't find solution still. But for now, I use on windows. There is not problem on windows. There is problem only on mac which is arm64 ( like M1 )

vania-pooh commented 4 months ago

@berkeroguz Chrome has no release for Linux ARM64 and will not work on Mac M1.

aplanche commented 4 months ago

@berkeroguz : ok, I see, strange thing is that it seems to work for a colleague also on mac arm64 (M1) with same docker desktop version etc as me, so did not find out yet what is really different to find out a workaround (use windows is no option atm)... @vania-pooh : do your proposed changes fix the issue and if yes, is there a plan to get this fix merged?

vania-pooh commented 4 months ago

@aplanche: not sure. If you provide some example source code to reproduce this - we could check.

aplanche commented 4 months ago

unfortunately did not find a simple usecase to reproduce, currently only reproducible on our internal project. @berkeroguz : do you know a simple usecase to reproduce the issue on a public project?