mirror of
				https://gitea.augustin64.fr/piair/MsRewards-Reborn.git
				synced 2025-11-04 07:33:53 +01:00 
			
		
		
		
	Trying to fix an issue when an account fail
This commit is contained in:
		
							
								
								
									
										10
									
								
								V6.py
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								V6.py
									
									
									
									
									
								
							@@ -612,9 +612,11 @@ def daily_routine(cred: UserCredentials, custom=False):
 | 
				
			|||||||
    try:
 | 
					    try:
 | 
				
			||||||
        if not custom:  # custom already is logged in
 | 
					        if not custom:  # custom already is logged in
 | 
				
			||||||
            login()
 | 
					            login()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    except Banned:
 | 
					    except Banned:
 | 
				
			||||||
        log_error("This account is locked.")
 | 
					        log_error("This account is locked.")
 | 
				
			||||||
        return
 | 
					        raise Banned()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    except Identity:
 | 
					    except Identity:
 | 
				
			||||||
        log_error("This account has an issue.")
 | 
					        log_error("This account has an issue.")
 | 
				
			||||||
        return
 | 
					        return
 | 
				
			||||||
@@ -746,12 +748,16 @@ def default_start():
 | 
				
			|||||||
            config.WebDriver.pc_driver.quit()
 | 
					            config.WebDriver.pc_driver.quit()
 | 
				
			||||||
            config.display.stop()
 | 
					            config.display.stop()
 | 
				
			||||||
            break
 | 
					            break
 | 
				
			||||||
 | 
					        except Banned:
 | 
				
			||||||
 | 
					            warning("this account is banned. Switching to next account")
 | 
				
			||||||
        except Exception as e:
 | 
					        except Exception as e:
 | 
				
			||||||
            log_error(f"Error not caught. Skipping this account. " + format_error(e))
 | 
					            log_error(f"Error not caught. Skipping this account. " + format_error(e))
 | 
				
			||||||
            critical(f"Error not caught. Skipping this account. {e}")
 | 
					            critical(f"Error not caught. Skipping this account. {e}")
 | 
				
			||||||
            config.WebDriver.pc_driver.quit()
 | 
					            config.WebDriver.pc_driver.quit()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        config.UserCredentials.next_account()
 | 
					        finally:
 | 
				
			||||||
 | 
					            config.UserCredentials.next_account()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    config.display.stop()
 | 
					    config.display.stop()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user