From e6e8bdaa069c96b4f98acedc983455bcb9191632 Mon Sep 17 00:00:00 2001 From: piair Date: Fri, 26 Apr 2024 11:17:18 +0200 Subject: [PATCH] Trying to find out why the part1 is starting --- .gitignore | 3 ++- V6.py | 12 +++++++----- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index d950f26..83241ef 100644 --- a/.gitignore +++ b/.gitignore @@ -15,4 +15,5 @@ nohup.out file.png *.ts LICENSE -README.md \ No newline at end of file +README.md +venv diff --git a/V6.py b/V6.py index 94e6920..f0db80b 100755 --- a/V6.py +++ b/V6.py @@ -1,4 +1,6 @@ #!/usr/bin/python3 +import random + from modules.Classes.Config import Config from modules.Classes.DiscordLogger import DiscordLogger from modules.Classes.UserCredentials import UserCredentials @@ -9,8 +11,6 @@ from modules.db import add_to_database from modules.driver_tools import * from modules.error import * -import random - # create a webdriver def create_driver(mobile=False): @@ -210,12 +210,12 @@ def all_cards(): welcome_tour = driver.find_element(By.ID, "welcome-tour") interest_button_box = welcome_tour.find_element(By.CLASS_NAME, "interest-buttons") interests = interest_button_box.find_elements(By.CLASS_NAME, "ng-binding") - debug("Got the following interests: "+str(interests)) - random.choice(interests).click() # Choose interest + debug("Got the following interests: " + str(interests)) + random.choice(interests).click() # Choose interest custom_sleep(1.5) claim_button = welcome_tour.find_element(By.ID, "claim-button") - claim_button.click() # submit + claim_button.click() # submit custom_sleep(1.5) return True @@ -476,10 +476,12 @@ def login(): def logged_in(): driver.get("https://login.live.com") custom_sleep(10) + debug(get_domain(driver)) if get_domain(driver) == "account.microsoft.com": return True return False + info("Logging in...") driver = config.WebDriver.driver try: if not logged_in():