diff --git a/V4.py b/V4.py index 2e232bc..2cc0c3c 100644 --- a/V4.py +++ b/V4.py @@ -476,7 +476,13 @@ def BingPcSearch(override = randint(30,35)): def BingMobileSearch(override = randint(20,25)): try : - MobileDriver = FirefoxMobile() + try : + MobileDriver = FirefoxMobile() + except Exception as e : + sleep(30) + LogError('echec de la creation du driver mobile') + MobileDriver = FirefoxMobile() + echec = 0 def Mlogin(echec): @@ -637,6 +643,7 @@ def LogPoint(account="unknown"): #log des points sur discord elem = driver.find_element(By.CSS_SELECTOR, '[title="Microsoft Rewards"]') elem.click() + CustomSleep(5) driver.switch_to.window(driver.window_handles[len(driver.window_handles) - 1]) CustomSleep(uniform(10,20)) try : @@ -732,6 +739,7 @@ def DailyRoutine(): except Exception as e: LogError(f'LogPoint : {e}') + def close(): driver.quit() quit()