0
votes

Is it possible to extend the default TimeoutException of Selenium?

My script is crashing on page loads over 300 seconds. My script is triggering a php script on my backend. If the php script runs for less than 300 seconds, everything is good, but on times where the script runs for longer, selenium throws the TimeoueException error.

TimeoutException: Message: timeout: Timed out receiving message from renderer: 300.000

Is there a way to tell Selenium to just wait until the script is done running?

I have tried expected_conditions and it does not help.

1
You can set the pageload timeout... with chrome_driver.set_page_load_timeout(seconds) Default is 30 seconds in chromedriver... - pcalkins

1 Answers

0
votes

Hey maybe this can solve your issue

from selenium.webdriver.support import expected_conditions as EC
wait = WebDriverWait(driver, 10)
element = wait.until(EC.element_to_be_clickable((By.ID, 'someid')))

it will wait till mentioned button is clickable.