Fix display: update n_chunks after chunk boundary filtering

The 'Chunk X/5' message was showing 5 even when only 2 chunks were
being processed (pages 1-50 and 51-55). n_chunks was not updated
after filtering chunks to stay before answer_section_start.
Cosmetic fix — the actual extraction was already correct.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Daniel 2026-04-01 04:13:50 +02:00
parent 8a220bb12e
commit 5a2fc7e187

View file

@ -130,6 +130,7 @@ def extract_quiz(
chunks = [(s, min(e, q_end)) for s, e in chunks if s <= q_end]
if not chunks:
chunks = [(section.start_page, q_end)]
n_chunks = len(chunks) # update display count after filtering
all_valid_questions = []
all_skipped = []