wrolpi/modules
Roland 821c3991be
Prevent doc_modeler from looping on persistent modeling failures
Addresses review feedback: the new `Doc.id IS NULL` gate keeps matching a
doc whose _model_doc fails without persisting a Doc row. With
>=DOC_PROCESSING_LIMIT such docs, every batch re-selected the same failing
files, `processed` never dropped below the limit, and the loop hung --
starving later docs. Reproduced with a patched _model_doc that always
raises.

Track attempted FileGroup ids per run and exclude them from the query, so
the candidate pool strictly shrinks and the loop always terminates. Failed
docs are retried on the next refresh (unchanged behavior).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 13:07:48 -06:00
..
archive Remove stale Postgres references after SQLite cutover. 2026-07-18 13:28:54 -06:00
docs Prevent doc_modeler from looping on persistent modeling failures 2026-07-20 13:07:48 -06:00
flasher Flasher: chip-mismatch guard, WROLPi firmware table, colorblind chip colors 2026-07-02 17:26:37 -06:00
inventory Postgres -> SQLite hard cutover: the database moves into the media directory. 2026-07-12 14:09:37 -06:00
map Migrating map downloaders. 2026-05-07 15:54:53 -06:00
videos Remove stale Postgres references after SQLite cutover. 2026-07-18 13:28:54 -06:00
zim kiwix: a corrupt zim must not bring down the whole server 2026-07-20 13:06:46 -06:00
__init__.py Move One-Time Pad encryption to the browser (#479) 2026-06-13 13:52:34 -06:00