From cddc3c226d574a84f77eabfb9a8a3f27bac6ef9f Mon Sep 17 00:00:00 2001 From: mARTin-B78 Date: Tue, 22 Sep 2026 05:05:06 +0200 Subject: [PATCH] docs: note the delete-region crop-cleanup gap found during magazine QA Co-Authored-By: Claude Sonnet 5 --- TODO.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/TODO.md b/TODO.md index b75611c..2e66f67 100644 --- a/TODO.md +++ b/TODO.md @@ -656,3 +656,13 @@ became behaviour ("peers through small windows, moves nimbly on spiral staircase rather than appearance, where the older sheet had "shoulder-length white hair, faded scar across forehead". Prefer the app's own Character Sheets flow over evidence-window shortcuts when appearance quality matters. + +- [ ] **Magazine: deleting a picture/chart/table region leaves its crop file and article + reference behind.** Found 2026-09-22 while cleaning up two invented figure regions by + hand. `delete_region()`/`DELETE .../regions/{block_id}` matches only the block's own id; + a picture/chart/table's derived crop has a *different* id (`p{page}-region-{block_id}`, + from `crop_visual_regions`), so deleting the block leaves that crop file on disk and its + id in any article's `images` list (the article would still try to show a picture of + content that's no longer recognised as one). Fix: when the deleted id is a block with a + crop derived from it, also remove the `p{page}-region-{id}` image entry, delete its file, + and strip that derived id (not just the block id) from every article's `images` list.