mirror of
https://github.com/GAM-team/GAM.git
synced 2026-07-04 04:41:35 +00:00
Catch revoke and throw nicer error
This commit is contained in:
@@ -482,7 +482,11 @@ class Credentials(google.oauth2.credentials.Credentials):
|
|||||||
def _locked_refresh(self, request):
|
def _locked_refresh(self, request):
|
||||||
"""Refreshes the credential's access token while the file lock is held."""
|
"""Refreshes the credential's access token while the file lock is held."""
|
||||||
assert self._lock.is_locked
|
assert self._lock.is_locked
|
||||||
super().refresh(request)
|
try:
|
||||||
|
super().refresh(request)
|
||||||
|
except google.auth.exceptions.RefreshError as e:
|
||||||
|
controlflow.system_error_exit(9, str(e))
|
||||||
|
|
||||||
|
|
||||||
def write(self):
|
def write(self):
|
||||||
"""Writes credentials to disk."""
|
"""Writes credentials to disk."""
|
||||||
|
|||||||
Reference in New Issue
Block a user