From 00156f9c27f5ab040bf661044326b02f33f074d7 Mon Sep 17 00:00:00 2001 From: Mathias Dail <93382891+MathiasExorde@users.noreply.github.com> Date: Thu, 22 Jun 2023 10:53:02 +0200 Subject: [PATCH] Reduce waiting times for selenium --- data/scraping/twitter/a7df32de3a60dfdb7a0b/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/data/scraping/twitter/a7df32de3a60dfdb7a0b/__init__.py b/data/scraping/twitter/a7df32de3a60dfdb7a0b/__init__.py index 953b69fe..d60d7aa5 100644 --- a/data/scraping/twitter/a7df32de3a60dfdb7a0b/__init__.py +++ b/data/scraping/twitter/a7df32de3a60dfdb7a0b/__init__.py @@ -501,10 +501,10 @@ def log_in(env="/.env", wait=4): logging.exception("An error occured retrieving cookies: %s",e) logging.info("[Twitter Chrome] refreshing to Home after cookie import.") - sleep(random.uniform(7, 10)) + sleep(random.uniform(1, 4)) driver.get(target_home_url) logging.info("[Twitter Chrome] Checking if we are on same URL...") - sleep(random.uniform(2, 5)) + sleep(random.uniform(1, 5)) # Check if we are indeed on the target URL logging.info("[Twitter Chrome] Current URL = %s",str(driver.current_url)) if not target_broad in driver.current_url: