diff options
author | Alexander_Kabui | 2024-05-24 16:27:51 +0300 |
---|---|---|
committer | Alexander_Kabui | 2024-05-24 16:27:51 +0300 |
commit | 8512d9a606fbfff864345d82c210e281a6d943bf (patch) | |
tree | 5b8383148a313f07a6bcf9b29db1e71b1f6a9780 | |
parent | 67c71507c84d474ac13681f16d994e7967321ddb (diff) | |
download | genenetwork3-8512d9a606fbfff864345d82c210e281a6d943bf.tar.gz |
Initiliaze second args to LLMError as query parameter.
-rw-r--r-- | gn3/errors.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gn3/errors.py b/gn3/errors.py index ad08ae5..8331028 100644 --- a/gn3/errors.py +++ b/gn3/errors.py @@ -109,7 +109,7 @@ def handle_generic(exc: Exception) -> Response: def handle_llm_error(exc: Exception) -> Response: """ Handle llm erros if not handled anywhere else. """ resp = jsonify({ - "query": exc.query if exc.query else "", + "query": exc.args[1], "error_type": type(exc).__name__, "error": ( exc.args[0] if bool(exc.args) else "Fahamu gnqa error occurred" |