This commit is contained in:
Ludwig Lehnert
2026-10-03 15:43:12 +00:00
parent 9944f2be1f
commit 2b23422fa3
9 changed files with 130 additions and 14 deletions
+5
View File
@@ -300,6 +300,11 @@ def process_next(conn, prefer_ocr=False, stop=None):
if row is None:
worker_state(conn, 'idle')
return False
if documents.is_excluded_filename(row['name']):
conn.execute('DELETE FROM documents WHERE id=?', (row['id'],))
conn.commit()
worker_state(conn, 'idle')
return True
source = conn.execute('SELECT * FROM document_sources WHERE id=?', (row['source_id'],)).fetchone()
if source is None:
return False