From 5214a7e0f34e87630ba818f225c123a074880936 Mon Sep 17 00:00:00 2001 From: dgtlmoon Date: Tue, 8 Feb 2022 18:24:25 +0100 Subject: [PATCH] Adding Env var "WEBDRIVER_DELAY_BEFORE_CONTENT_READY" to wait n seconds before extracting the text from the browser --- changedetectionio/content_fetcher.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changedetectionio/content_fetcher.py b/changedetectionio/content_fetcher.py index 72491753..436a652d 100644 --- a/changedetectionio/content_fetcher.py +++ b/changedetectionio/content_fetcher.py @@ -120,7 +120,7 @@ class html_webdriver(Fetcher): # raise EmptyReply(url=url, status_code=r.status_code) # @todo - dom wait loaded? - time.sleep(5) + time.sleep(os.getenv("WEBDRIVER_DELAY_BEFORE_CONTENT_READY", 5)) self.content = driver.page_source self.headers = {}