clean up log.error (#1109)
This commit is contained in:
parent
bd84329a08
commit
4fee123e72
1 changed files with 69 additions and 65 deletions
|
|
@ -464,8 +464,8 @@ class OAuthClientProvider(httpx.Auth):
|
|||
await self.context.storage.set_tokens(token_response)
|
||||
|
||||
return True
|
||||
except ValidationError as e:
|
||||
logger.error(f"Invalid refresh response: {e}")
|
||||
except ValidationError:
|
||||
logger.exception("Invalid refresh response")
|
||||
self.context.clear_tokens()
|
||||
return False
|
||||
|
||||
|
|
@ -522,8 +522,8 @@ class OAuthClientProvider(httpx.Auth):
|
|||
token_request = await self._exchange_token(auth_code, code_verifier)
|
||||
token_response = yield token_request
|
||||
await self._handle_token_response(token_response)
|
||||
except Exception as e:
|
||||
logger.error(f"OAuth flow error: {e}")
|
||||
except Exception:
|
||||
logger.exception("OAuth flow error")
|
||||
raise
|
||||
|
||||
# Add authorization header and make request
|
||||
|
|
|
|||
Loading…
Reference in a new issue