Fixed missing imports bug and fixed linting

This commit is contained in:
Saifeddine ALOUI
2025-01-25 00:55:07 +01:00
parent e060fa6abb
commit 06c9e4e454
20 changed files with 59 additions and 90 deletions

View File

@@ -684,7 +684,9 @@ def create_app(args):
trace_exception(e)
logging.error(f"Error indexing file {file_path}: {str(e)}")
ASCIIColors.info(f"Indexed {len(new_files)} documents from {args.input_dir}")
ASCIIColors.info(
f"Indexed {len(new_files)} documents from {args.input_dir}"
)
except Exception as e:
logging.error(f"Error during startup indexing: {str(e)}")
yield
@@ -917,7 +919,6 @@ def create_app(args):
else:
logging.warning(f"No content extracted from file: {file_path}")
@app.post("/documents/scan", dependencies=[Depends(optional_api_key)])
async def scan_for_new_documents():
"""