mirror of
https://github.com/open-webui/open-webui
synced 2025-06-26 18:26:48 +00:00
Fix process/files/batch
This commit is contained in:
@@ -548,10 +548,17 @@ def add_files_to_knowledge_batch(
|
||||
files.append(file)
|
||||
|
||||
# Process files
|
||||
result = process_files_batch(BatchProcessFilesForm(
|
||||
files=files,
|
||||
collection_name=id
|
||||
))
|
||||
try:
|
||||
result = process_files_batch(BatchProcessFilesForm(
|
||||
files=files,
|
||||
collection_name=id
|
||||
))
|
||||
except Exception as e:
|
||||
log.error(f"add_files_to_knowledge_batch: Exception occurred: {e}", exc_info=True)
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_400_BAD_REQUEST,
|
||||
detail=str(e)
|
||||
)
|
||||
|
||||
# Add successful files to knowledge base
|
||||
data = knowledge.data or {}
|
||||
|
||||
Reference in New Issue
Block a user