diff options
| author | John Nduli | 2024-10-18 15:06:35 +0300 |
|---|---|---|
| committer | Frederick Muriuki Muriithi | 2024-10-18 09:28:40 -0500 |
| commit | 27531c0a1350097ca36a555b8546bc282948de04 (patch) | |
| tree | b209f28f6da28fc0384ddfe1145cfe413f2bf8e3 /gn3/errors.py | |
| parent | 1aeb61f50567e2400c3cc1a18eeef1e59bdc68ac (diff) | |
| download | genenetwork3-27531c0a1350097ca36a555b8546bc282948de04.tar.gz | |
refactor: move definition of auth errs and remove auth cli utils
Diffstat (limited to 'gn3/errors.py')
| -rw-r--r-- | gn3/errors.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gn3/errors.py b/gn3/errors.py index cd795e8..46483db 100644 --- a/gn3/errors.py +++ b/gn3/errors.py @@ -16,7 +16,7 @@ from authlib.oauth2.rfc6749.errors import OAuth2Error from flask import Flask, jsonify, Response, current_app from gn3.oauth2 import errors as oautherrors -from gn3.auth.authorisation.errors import AuthorisationError +from gn3.oauth2.errors import AuthorisationError from gn3.llms.errors import LLMError def add_trace(exc: Exception, jsonmsg: dict) -> dict: @@ -60,7 +60,7 @@ def handle_authorisation_error(exc: AuthorisationError): return jsonify(add_trace(exc, { "error": type(exc).__name__, "error_description": " :: ".join(exc.args) - })), exc.error_code + })), 500 def handle_oauth2_errors(exc: OAuth2Error): |
