Repository navigation
Fix spaCy model loading in ingestion CI - #36176
Conversation
Code Review ✅ Approved🟡 Medium risk · Constraining preshed below 3.0.14 across ingestion extras may block compatible future releases or create dependency conflicts in ingestion installs. Pins VerificationRules No rules evaluated Functional validation Not enabledAuto-approval Not enabledFor more verification details, comment OptionsDisplay: compact → Showing compact verification results. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
🚦 Removed from the merge queue —
|
🚦 Removed from the merge queue —
|
Describe your changes:
Fixes ingestion CI image builds and auto-classification initialization failing while loading
en_core_web_mdwithOverflowError: Python int too large to convert to C ssize_t.preshed==3.0.14rejects unsigned 64-bit tokenizer hashes. Constrain it to<3.0.14in thepii-processor,sample-data, andpresidio-analyzerextras. Aggregate extras inherit the constraint, covering OSS and Collate ingestion installs. This is a temporary compatibility constraint; newer preshed releases require verification before relaxing it.Type of change:
High-level design:
Not applicable — one-file dependency compatibility fix. No Dockerfile, workflow, or application changes.
Verification:
pii-processor,sample-data,presidio-analyzer,all,all-dev-env,slim,playwright,test, anddev. The new constraint is present in all nine.preshed==3.0.14anden_core_web_md==3.8.0.preshed==3.0.13; fresh-process model loading and entity recognition passed (3/3).metadata install-classification-models --languages encommand, then changed only preshed to 3.0.13 and reran it successfully. Other newly released native dependencies remained unchanged.ruff check ingestion/setup.py,ruff format --check ingestion/setup.py, andgit diff --checkpassed.Manual testing performed:
Install preshed 3.0.14 and load
en_core_web_mdto reproduce the overflow. Install the updated extra requirements and repeat model loading plus recognition of a synthetic sentence; both succeed with preshed 3.0.13.UI screen recording:
Not applicable — no UI changes.
Checklist:
REVIEW.md; no blocking findings.ingestion/setup.pymaps to the built-wheel metadata, real pip resolver, and model-loading checks above.skip-pr-checks).Reviewed commit:
1a04fe3b5994e0f41fa339faf9f7f8970603f395.

Confidence Score: 5/5
The PR appears safe to merge; no actionable issues were found.Summary
Adds
preshed<3.0.14to avoid the reported spaCy model-loading failure.Reviews (1) · Last reviewed commit: "Fix spaCy tokenizer overflow in ingestio..." · Reviewed by Greptile