From e8c929dda164040e1a054ca1a1706909ccae0a9c Mon Sep 17 00:00:00 2001 From: sammiee5311 Date: Sun, 17 Oct 2021 16:38:11 +0900 Subject: [PATCH] Update raise exception in `Webauth.cli_login` --- steam/webauth.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/steam/webauth.py b/steam/webauth.py index 54bfe92..fdb6930 100644 --- a/steam/webauth.py +++ b/steam/webauth.py @@ -224,6 +224,8 @@ class WebAuth(object): raise EmailCodeRequired(resp['message']) elif resp.get('requires_twofactor', False): raise TwoFactorCodeRequired(resp['message']) + elif 'short time period' in resp.get('message', ''): + raise TooManyTimesFailed(resp['message']) else: self.password = '' raise LoginIncorrect(resp['message']) @@ -404,3 +406,6 @@ class EmailCodeRequired(WebAuthException): class TwoFactorCodeRequired(WebAuthException): pass + +class TooManyTimesFailed(WebAuthException): + pass \ No newline at end of file