This post explains how to handle Timed out receiving message from renderer issue with the help of selenium webdriver.
Whenever you are loading some page with the help of selenium driver, then driver script wait till page is completely loaded. But sometime webdriver takes 3 to 4 mins to load page, in that case you will see TimeoutException exception in your console.
Solution to Overcome/Solve Timed out receiving message from renderer issue :
When Page Loading takes too much time and you need to stop downloading additional subresources (images, css, js etc) you can change the pageLoadStrategy through the webdriver.
As of this writing, pageLoadStrategy supports the following values :
This strategy causes Selenium to wait for the full page loading (html content and sub resources downloaded and parsed).
2. eager :
This strategy causes Selenium to wait for the DOMContentLoaded event (html content downloaded and parsed only).
3. none :
This strategy causes Selenium to return immediately after the initial page content is fully received (html content downloaded).
NOTE : By default, when Selenium loads a page, it follows the normal pageLoadStrategy.
Example :
Hope this example solve your timeout exception issue in selenium. In case of any issues, please do comment in comment box below.
Whenever you are loading some page with the help of selenium driver, then driver script wait till page is completely loaded. But sometime webdriver takes 3 to 4 mins to load page, in that case you will see TimeoutException exception in your console.
Jul 06, 2018 4:07:01 PM org.openqa.selenium.remote.ProtocolHandshake createSession INFO: Detected dialect: OSS [1530864721.448][SEVERE]: Timed out receiving message from renderer: 298.565 [1530864721.449][SEVERE]: Timed out receiving message from renderer: -0.004 [1530864721.469][SEVERE]: Timed out receiving message from renderer: -0.024
Solution to Overcome/Solve Timed out receiving message from renderer issue :
When Page Loading takes too much time and you need to stop downloading additional subresources (images, css, js etc) you can change the pageLoadStrategy through the webdriver.
As of this writing, pageLoadStrategy supports the following values :
Page load strategy for Chrome driver (Updated till Selenium v3.12.0)1. normal:
This strategy causes Selenium to wait for the full page loading (html content and sub resources downloaded and parsed).
2. eager :
This strategy causes Selenium to wait for the DOMContentLoaded event (html content downloaded and parsed only).
3. none :
This strategy causes Selenium to return immediately after the initial page content is fully received (html content downloaded).
NOTE : By default, when Selenium loads a page, it follows the normal pageLoadStrategy.
Example :
System.setProperty("webdriver.chrome.driver","E:\\selenium\\chromedriver_2.41\\chromedriver.exe"); //mention the below chrome option to solve timeout exception issue ChromeOptions options = new ChromeOptions(); options.setPageLoadStrategy(PageLoadStrategy.NONE); // Instantiate the chrome driver driver = new ChromeDriver(options);
Hope this example solve your timeout exception issue in selenium. In case of any issues, please do comment in comment box below.
While executing testcase getting
ReplyDelete[1540801449.733][SEVERE]: Timed out receiving message from renderer: 600.000
[1540801749.734][SEVERE]: Timed out receiving message from renderer: 300.000
[1540802349.734][SEVERE]: Timed out receiving message from renderer: 600.000
[1540802349.734][SEVERE]: Timed out receiving message from renderer: -600.002
[1540802649.739][SEVERE]: Timed out receiving message from renderer: 300.000
[1540803249.739][SEVERE]: Timed out receiving message from renderer: 600.000
[1540803249.740][SEVERE]: Timed out receiving message from renderer: -600.001
ChromeDriver : 2.43.600210
Chrome Version : 70.0.3538.77
apply below line code in selenium script :
DeleteChromeOptions options = new ChromeOptions();
options.setPageLoadStrategy(PageLoadStrategy.NONE);
// Instantiate the chrome driver
driver = new ChromeDriver(options);
Tho PageLoadStrategy.EAGER is not supported for now.
ReplyDeleteGreat thanks for this article, helped a lot.
how to handle the same issue in internet explorer
ReplyDeleteHI,
ReplyDeleteThanks for your solution but it is not working in my case. When I am running it on my machine(without jenkins). chrome is initiated successfully and automation scripts are executed but when I do the same from jenkins. It keeps on giving below error:
[1554447408.210][SEVERE]: Timed out receiving message from renderer: 600.000
I have tried your solution also but not helping.
Chrome browser version- Version 73.0.3683.86 (Official Build) (64-bit)
chrome driver exe: 73(recent stable version)
Selenium: 3.12
Can you pls help
Same Issue here
DeleteSame Issue , Searching for answer
DeleteHi Tigranm and Rohanraviyadav, please tell if you found the solution for jenkin timeout error
DeleteIam facing the same issue, Did you get the solution?
ReplyDeleteDid we get solution for this issue?
ReplyDeleteany solution for this issue?
ReplyDeletethanks
ReplyDeletedidnt work for me, getting this error
ReplyDeleteTimed out receiving message from renderer: 0.100
Same issue any other solution?
ReplyDeletecan someone please respond on this?
ReplyDeleteI tried below option:
ChromeOptions options = new ChromeOptions();
options.setPageLoadStrategy(PageLoadStrategy.NONE);
still not working. Getting same issue.
add options= options into webdriver.Chrome()
DeleteThis is not going to work :
ReplyDeleteChromeOptions options = new ChromeOptions();
options.setPageLoadStrategy(PageLoadStrategy.NONE);
this will only stop the processing which is not a solution really .
I had the same problem:
ReplyDelete[1590022141.990][SEVERE]: Timed out receiving message from renderer: 300.000
[1590022141.991][SEVERE]: Timed out receiving message from renderer: -0.001
It happened alter the application changes were made for performance improvements.
I had the same driver working fine and that timeout problems started to appear
I my case PageLoadStrategy change to NONE fixed the issue!
I used it, errors are gone but initiates 2 web browsers ... I mean I prefer that though, but if someone figures a fix for that, would be awesome
ReplyDeleteAny resolution for this? I am also getting "Timed out receiving message from renderer: 300.000 while switching windows"?
ReplyDeleteI am also facing the same issue.Did u have any solution for this issue
DeleteI have tried this, getting below error:
ReplyDeleteException in thread "main" org.openqa.selenium.interactions.MoveTargetOutOfBoundsException: move target out of bounds
I am also facing the same timeout issue when i triggered it from jenkins. Can someone ans this?
ReplyDelete