Environment
- Windows 10
- Python 3.11.9
- PyTorch 2.5.1+cu121
- CUDA available with NVIDIA GeForce GTX 960M
glossapi_rs_cleaner built and installed successfully
Reproduction
From the development branch:
python -m pytest tests/test_pipeline_smoke.py -rs
The test suite starts correctly and CUDA is detected, but two smoke tests fail while generating PDFs containing Greek text.
Observed behaviour
The failures originate in fpdf with errors such as:
FPDFUnicodeEncodingException: Character "Κ" ... is outside the range of characters supported by the font used: "helvetica"
The test helper currently uses:
_FONT_PATH = Path("/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf")
On Windows that Linux-specific path does not exist, so _write_pdf() falls back to Helvetica. Helvetica cannot encode the Greek strings used by the smoke tests, which causes the failures before the actual pipeline assertions are reached.
Expected behaviour
The smoke tests should be able to generate their Unicode test PDFs on supported development platforms without depending on a Linux-only font path.
Possible direction
A platform-independent Unicode font lookup for the tests, or a small bundled test font, would avoid the fallback to Helvetica and make the smoke tests portable across Windows and Linux.
I found this while setting up GlossAPI on Windows as a new contributor. I am happy to work on a small fix if this approach makes sense to the maintainers.
Environment
glossapi_rs_cleanerbuilt and installed successfullyReproduction
From the
developmentbranch:The test suite starts correctly and CUDA is detected, but two smoke tests fail while generating PDFs containing Greek text.
Observed behaviour
The failures originate in
fpdfwith errors such as:The test helper currently uses:
On Windows that Linux-specific path does not exist, so
_write_pdf()falls back to Helvetica. Helvetica cannot encode the Greek strings used by the smoke tests, which causes the failures before the actual pipeline assertions are reached.Expected behaviour
The smoke tests should be able to generate their Unicode test PDFs on supported development platforms without depending on a Linux-only font path.
Possible direction
A platform-independent Unicode font lookup for the tests, or a small bundled test font, would avoid the fallback to Helvetica and make the smoke tests portable across Windows and Linux.
I found this while setting up GlossAPI on Windows as a new contributor. I am happy to work on a small fix if this approach makes sense to the maintainers.