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

Ruby persistent client fails with wrong number of arguments error #7158

Closed
theDogOfPavlov opened this issue Apr 30, 2019 · 2 comments
Closed
Labels

Comments

@theDogOfPavlov
Copy link

🐛 Bug Report

Ruby persistent client fails with wrong number of arguments error

This is a new issue introduced with 3.142.0 and does not affect 3.141.0

To Reproduce

Instantiating the driver using the persistent client:

profile = Selenium::WebDriver::Firefox::Profile.new
client = Selenium::WebDriver::Remote::Http::Persistent.new
browser = Watir::Browser.new :firefox, profile: profile, http_client: client

Produces the error:

12: from /var/lib/gems/2.5.0/gems/watir-6.16.5/lib/watir/browser.rb:46:in `initialize'
11: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver.rb:88:in `for'
10: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/common/driver.rb:54:in `for'
9: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/firefox/driver.rb:33:in `new'
8: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/firefox/driver.rb:33:in `new'
7: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/firefox/marionette/driver.rb:44:in `initialize'
6: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/remote/bridge.rb:102:in `create_session'
5: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/remote/bridge.rb:167:in `execute'
4: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/remote/http/common.rb:64:in `call'
3: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/remote/http/default.rb:82:in `request'
2: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/remote/http/persistent.rb:54:in `response_for'
1: from /var/lib/gems/2.5.0/gems/selenium-webdriver-3.142.0/lib/selenium/webdriver/remote/http/default.rb:71:in `http'
/var/lib/gems/2.5.0/gems/net-http-persistent-3.0.1/lib/net/http/persistent.rb:706:in `start': wrong number of arguments (given 0, expected 1) (ArgumentError)

Expected behaviour

Should instantiate without error.

Environment

OS: Ubuntu bionic 64 bit
Browser: Mozilla Firefox
Browser version: 67.0b2
Browser Driver version: GeckoDriver 0.24
Language Bindings version: ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-linux-gnu]
Selenium Webdriver: 3.142.0
net-http-persistent: 3.0.1

@titusfortner
Copy link
Member

We will take a look, but a big new feature post 3.141 is that the default http client now takes advantage of keep-alive by default and you shouldn't need to use Persistent to get this functionality.

@p0deje p0deje closed this as completed in 6b069e2 May 3, 2019
@theDogOfPavlov
Copy link
Author

Thanks for the fast turn-around!

@lock lock bot locked and limited conversation to collaborators Aug 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants