mirror of
https://github.com/open-webui/open-webui
synced 2025-03-21 12:26:50 +00:00
fix: log exception when issues of collection querying
This commit is contained in:
parent
e510c8b11f
commit
53f03f6556
@ -150,8 +150,8 @@ def query_collection(
|
|||||||
embedding_function=embedding_function,
|
embedding_function=embedding_function,
|
||||||
)
|
)
|
||||||
results.append(result)
|
results.append(result)
|
||||||
except Exception:
|
except Exception as e:
|
||||||
pass
|
log.exception(f"Error when querying the collection: {e}")
|
||||||
else:
|
else:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
@ -178,8 +178,11 @@ def query_collection_with_hybrid_search(
|
|||||||
r=r,
|
r=r,
|
||||||
)
|
)
|
||||||
results.append(result)
|
results.append(result)
|
||||||
except Exception:
|
except Exception as e:
|
||||||
pass
|
log.exception(
|
||||||
|
"Error when querying the collection with "
|
||||||
|
f"hybrid_search: {e}"
|
||||||
|
)
|
||||||
return merge_and_sort_query_results(results, k=k, reverse=True)
|
return merge_and_sort_query_results(results, k=k, reverse=True)
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user