Skip to content

Fix/ingestion pdf dir clean clone - #5

Merged
johnma96 merged 2 commits into
mainfrom
fix/ingestion-pdf-dir-clean-clone
Aug 13, 2026
Merged

johnma96 merged 2 commits into
mainfrom
fix/ingestion-pdf-dir-clean-clone

Conversation

@johnma96

Copy link
Copy Markdown
Owner

No description provided.

… from disk

_download_pdf assumed data/papers/ already existed, which is only true if
ensure_dirs() ran first. It never does in a clean clone, so extract_text_pdf
raised FileNotFoundError. mkdir(parents=True, exist_ok=True) before the
write makes the service robust regardless of call order.

test_extract_text_pdf still wrote through to the real data/papers/ even
after the previous fix (only the PDF bytes were mocked, not the write
target). Patches PAPERS_DIR to tmp_path so the test never touches the repo.

Verified in a genuinely fresh clone this time, not just the working copy —
T14 was marked done on 12/08 without that check and this exact bug slipped
through.
T14 was checked off on 12/08 without verifying in a clean clone — it
still failed. Corrected the note to record what actually happened and
the real completion date. T17 (merge to main) happened today via PR#4.
@johnma96
johnma96 merged commit 6e4e730 into main Aug 13, 2026
1 check failed
@johnma96
johnma96 deleted the fix/ingestion-pdf-dir-clean-clone branch August 13, 2026 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant