fix: update file skipping logic for failed documents in Google Drive indexer

- Modified the `_should_skip_file` function to skip previously failed documents during processing, improving error handling.
- Updated the corresponding test to reflect the new behavior, ensuring that failed documents are correctly identified and skipped during automatic sync.
This commit is contained in:
Anish Sarkar 2026-03-27 20:01:08 +05:30
parent 3ce831d01d
commit 4e0749f907
2 changed files with 6 additions and 5 deletions

View file

@ -150,7 +150,7 @@ async def _should_skip_file(
return True, f"File renamed: '{old_name}''{file_name}'"
if not DocumentStatus.is_state(existing.status, DocumentStatus.READY):
return False, None
return True, "skipped (previously failed)"
return True, "unchanged"