updated css selectors for new page
This commit is contained in:
		
							
								
								
									
										8
									
								
								main.py
									
									
									
									
									
								
							
							
						
						
									
										8
									
								
								main.py
									
									
									
									
									
								
							| @@ -185,7 +185,7 @@ def doLogin() -> None: | ||||
|      | ||||
|     driver.get(config["gateway"]) | ||||
|     wait = WebDriverWait(driver, 9999) | ||||
|     wait.until(EC.presence_of_element_located((By.CSS_SELECTOR, "img[alt=Logo],img[alt=logo]"))) | ||||
|     wait.until(EC.presence_of_element_located((By.CSS_SELECTOR, 'img[alt="app logo"]'))) | ||||
|      | ||||
|     closeBrowser(driver, dkey) | ||||
|  | ||||
| @@ -206,7 +206,7 @@ driver.get(url) | ||||
| wait = WebDriverWait(driver, timeout) | ||||
| wait.until(AnyEc( | ||||
|     EC.url_contains("microsoft"), | ||||
|     EC.presence_of_element_located((By.CSS_SELECTOR, "img[alt=Logo],img[alt=logo]")) | ||||
|     EC.presence_of_element_located((By.CSS_SELECTOR, 'img[alt="app logo"]')) | ||||
| )) | ||||
|  | ||||
| if "microsoft" in driver.current_url: | ||||
| @@ -217,7 +217,7 @@ if "microsoft" in driver.current_url: | ||||
|     driver.get(url) | ||||
|     wait = WebDriverWait(driver, timeout) | ||||
|  | ||||
| wait.until(EC.presence_of_element_located((By.CSS_SELECTOR, "img[alt=Logo],img[alt=logo]"))) | ||||
| wait.until(EC.presence_of_element_located((By.CSS_SELECTOR, 'img[alt="app logo"]'))) | ||||
|  | ||||
| driver.implicitly_wait(0) | ||||
| continueBtn = driver.find_elements(By.ID, "btnContinue") | ||||
| @@ -228,7 +228,7 @@ if len(continueBtn) > 0: | ||||
|     infoLogger.log("Detected session already running button") | ||||
|     continueBtn.click() | ||||
|  | ||||
| wait.until(EC.presence_of_element_located((By.ID, "table_welcome_2"))) | ||||
| wait.until(EC.presence_of_element_located((By.CSS_SELECTOR, ".welcomeMessageText"))) | ||||
|  | ||||
| infoLogger.log("Extracting cookies...") | ||||
| DSID = driver.get_cookie("DSID")["value"] | ||||
|   | ||||
		Reference in New Issue
	
	Block a user