robotframework / robotframework/SeleniumLibrary

SessionNotCreatedException using Selenoid and chrome version 56.0

Aperta
#1,779 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Lingua principale
Python
Stelle
1.5k
Fork
787
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

Issue

I would need some help getting the RF-SeleniumLibrary work with Selenoid. I am testing a website with two versions of Chrome: v103 & v56. The keyword works for newer versions of Chrome, but fails for older ones (56.0 for example. I think it has something to do with the parameters I am setting, which are not compatible with such a low version, as I am able to start chrome w/ version 56.0 manually in the Selenoid-UI.

This is the keyword I use to open the website on a remote browser using Selenoid:

Steps to reproduce the issue

Keyword:

Open Specific Browser Version
    [Arguments]    ${url}    ${browser}    ${version}
    ${caps}=    Create Dictionary    version=${version}
    Wait Until Keyword Succeeds
    ...    30 seconds
    ...    5 s
    ...    Open Browser
    ...    url=${url}
    ...    browser=${browser}
    ...    remote_url=${selenoid_server}
    ...    desired_capabilities=${caps}

Call it:

Open Specific Browser Version    https://google.come    chrome    103.0

Error messages and additional information

This works with Chrome 103.0, but results in an error with Chrome 56.0:

| FAIL |
Keyword 'frontend.Open Browser To Dashboard' failed after retrying for 30 seconds. The last error was: Keyword 'Open Browser' failed after retrying for 30 seconds. The last error was: SessionNotCreatedException: Message: session not created exception: Missing or invalid capabilities
  (Driver info: chromedriver=2.29.461571 (8a88bbe0775e2a23afda0ceaf2ef7ee74e822cc5),platform=Linux 5.18.11-100.fc35.x86_64 x86_64)

If I change the desired_capabilities parameter to options, the Chrome v103.0 also does not work. Both versions throw the following error:

Keyword 'frontend.Open Browser To Dashboard' failed after retrying for 30 seconds. The last error was: Keyword 'Open Browser' failed after retrying for 30 seconds. The last error was: AttributeError: to_capabilities

However, using selenoid-ui, it's possible to start a Chrome v56 instance manually, so I guess I have some wrong parameters set.

Selenoid-UI console log:

Initialize...

Connecting to ws://127.0.0.1:8080/ws/logs/742684cc34796c87fd0145c735281faa...
Connected!

 --- x11vnc loop: 1 ---

Starting ChromeDriver 2.29.461571 (8a88bbe0775e2a23afda0ceaf2ef7ee74e822cc5) on port 4444
All remote connections are allowed. Use a whitelist instead!
[0.036][INFO]: COMMAND InitSession {
   "capabilities": {
      "alwaysMatch": {
         "browserName": "chrome",
         "browserVersion": "56.0"
      },
      "firstMatch": [ {

      } ]
   },
   "desiredCapabilities": {
      "browserName": "chrome",
      "enableVNC": true,
      "labels": {
         "manual": "true"
      },
      "name": "Manual session",
      "sessionTimeout": "60m",
      "version": "56.0"
   }
}

Can someone maybe help me out? :) Thanks & BR

Environment

Browser: Name and version (Usually available from the about dialogue.)
Browser driver: Name and version
Operating System: Name and version (Linux, Ubuntu 18.04)
Libraries

  • Robot Framework: 5.0.1
  • SeleniumLibrary: 6.0.0
  • Interpreter: Python 3.10

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Direzione di ricerca

Riproduci il problema con la keyword di Robot Framework “Open Specific Browser Version”, concentrandoti sulla relativa chiamata a Open Browser, su desired_capabilities e sull’errore di Chrome 56.0. Confronta le capabilities inviate per Chrome 103.0 con i dettagli della sessione di Selenoid-UI; il lavoro è completato quando viene determinata la configurazione compatibile oppure viene documentata questa limitazione per SeleniumLibrary 6.0.0.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
python
Ambito
testing-qa
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Da chiarire
Idoneità per principianti
25/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.