Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Selenium::Firefox ... You need to specify a browser or driver #488

Open
davewood opened this issue Sep 14, 2023 · 3 comments
Open

Selenium::Firefox ... You need to specify a browser or driver #488

davewood opened this issue Sep 14, 2023 · 3 comments

Comments

@davewood
Copy link

things keep changing and breaking my working setup and im trying to figure out the most recent change.

this is my selenium service, running in a container (image: selenium/standalone-firefox)

epplication-selenium | Selenium Grid Standalone configuration:
epplication-selenium | [network]
epplication-selenium | relax-checks = true
epplication-selenium |
epplication-selenium | [node]
epplication-selenium | session-timeout = "300"
epplication-selenium | override-max-sessions = false
epplication-selenium | detect-drivers = false
epplication-selenium | drain-after-session-count = 0
epplication-selenium | max-sessions = 1
epplication-selenium |
epplication-selenium | [[node.driver-configuration]]
epplication-selenium | display-name = "firefox"
epplication-selenium | stereotype = '{"browserName": "firefox", "browserVersion": "117.0", "platformName": "Linux"}'
epplication-selenium | max-sessions = 1
epplication-selenium |
epplication-selenium | Starting Selenium Grid Standalone...

...

epplication-selenium | 08:43:06.495 INFO [NodeOptions.report] - Adding firefox for {"browserName": "firefox","browserVersion": "117.0","platformName": "linux","se:noVncPort": 7900,"se:vncEnabled": true} 1 times

...

epplication-selenium | 08:43:06.873 INFO [Standalone.execute] - Started Selenium Standalone 4.12.1 (revision 8e34639b11): http://172.19.0.3:4444

when i try to connect

      my $driver = Selenium::Firefox->new(
          remote_server_addr => $conf{host},
          port => $conf{port},
      );

i see this error

epplication-selenium | 09:07:39.949 INFO [LocalDistributor.newSession] - Session request received by the Distributor:
epplication-selenium |  [Capabilities {acceptInsecureCerts: true}]
epplication-selenium | 09:07:40.077 WARN [SeleniumManager.lambda$runCommand$1] - You need to specify a browser or driver
epplication-selenium | 09:07:40.081 WARN [DriverServiceSessionFactory.apply] - Error while creating session with the driver service. Unable to obtain: Capabilities {acceptInsecureCerts: true}, error Command failed with code: 65, executed: [--browser, , --output, json]
epplication-selenium | You need to specify a browser or driver

@davewood
Copy link
Author

davewood commented Sep 18, 2023

it works with an older docker-selenium version, buit not with latest.

docker-compose.yml
image: selenium/standalone-firefox:114.0-geckodriver-0.33-grid-4.10.0-20230614

and im a bit confused because the README says (https://github.com/teodesian/Selenium-Remote-Driver/blob/master/README.md)

This module is also not ready for SeleniumHQ's 4.0 series JAR. For compatibility with that, try our next generation selenium client: Selenium::Client

@teodesian
Copy link
Owner

Geckodriver, for a long time had not removed the code to connect via earlier selenium connection strings. That's why it still worked. If that has changed, then things would indeed break the same way they do for the selenium 4 Jar.

@teodesian
Copy link
Owner

nevertheless this probably means there are no viable workarounds to use this module any longer. I suppose that finally moves this up to the top of my list.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants