Timeout error in selenium - Timeout Error with Selenium Capybara Cucumber Ruby

0 votes

When executing the scenarios in cucumber ruby using Capybara I am facing error. After few Scenarios are executed, time out error arises we're not able to proceed to next scenario.

Following error is displayed:

Timeout::Error (Timeout::Error)
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:146:in `rescue in rbuf_fill'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:140:in `rbuf_fill'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:122:in `readuntil'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/protocol.rb:132:in `readline'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:2563:in `read_status_line'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:2552:in `read_new'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1320:in `block in transport_request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1317:in `catch'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1317:in `transport_request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1294:in `request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1287:in `block in request'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:746:in `start'
  /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/net/http.rb:1285:in `request'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/http/default.rb:83:in `response_for'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/http/default.rb:39:in `request'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/http/common.rb:40:in `call'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/bridge.rb:634:in `raw_execute'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/bridge.rb:612:in `execute'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/remote/bridge.rb:361:in `deleteAllCookies'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/selenium-webdriver-2.37.0/lib/selenium/webdriver/common/options.rb:67:in `delete_all_cookies'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara/selenium/driver.rb:84:in `reset!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara/session.rb:77:in `reset!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara.rb:245:in `block in reset_sessions!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara.rb:245:in `each'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara.rb:245:in `reset_sessions!'
  /usr/local/rvm/gems/ruby-1.9.3-p448/gems/capybara-2.1.0/lib/capybara/cucumber.rb:10:in `After'
We are using Capybara 2.1.0 version and Cucumber 1.3.8.

Any suggestion would be welcome :)

Mar 26, 2018 in Selenium by Sanju
2,326 views

1 answer to this question.

0 votes
The only reason for a timeout error is if your Chrome WebDriver is outdated. Update that first. Also, Capybara 2.1.0 is very old. Try updating it too. Hopefully it should now work. Hope the answer helps :)
answered Mar 26, 2018 by nsv999
• 5,500 points

Related Questions In Selenium

0 votes
1 answer

How can I add Cucumber Jar files in Eclipse to use with Selenium Webdriver?

Hey Eshan, follow these steps to add ...READ MORE

answered May 23, 2019 in Selenium by Abha
• 28,140 points
5,999 views
0 votes
1 answer
0 votes
1 answer

How to take Screenshot of a webpage in Selenium with Ruby

Hi Sunita, you can use following code ...READ MORE

answered Aug 26, 2019 in Selenium by Anvi
• 14,150 points
1,591 views
+1 vote
1 answer

ElementNotVisibleException in selenium with cucumber

@Mahesh, can you share your code where ...READ MORE

answered Oct 10, 2019 in Selenium by Abha
• 28,140 points
1,098 views
0 votes
1 answer

How to Hover using Mouse in python using Webdriver

from selenium.webdriver.common.action_chains import ActionChains def hover(self): ...READ MORE

answered Aug 8, 2018 in Selenium by Meci Matt
• 9,460 points
2,457 views
+1 vote
2 answers

Python with Selenium issue: “Chrome is being controlled by automated test software”

from selenium import webdriver chrome_options = webdriver.ChromeOptions() chrome_options.add_experimental_option("useAutomationExtension", False) chrome_options.add_experimental_option("excludeSwitches",["enable-automation"]) driver ...READ MORE

answered Apr 20, 2020 in Selenium by Manoj
16,003 views
0 votes
1 answer
+2 votes
2 answers

How can I press ENTER key with the execute_script in selenium python?

The below code containing Keys.ENTER might just ...READ MORE

answered Mar 28, 2018 in Selenium by nsv999
• 5,500 points
27,417 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP