v17.3.0

ocrmypdf/OCRmyPDFv17.3.0Feb 21, 2026by github-actions[bot]

AI Summary

This release addresses critical bugs in the Python API and improves PDF OCR handling. Key fixes include correcting the language parameter handling, resolving the tesseract_timeout issue that caused empty OCR output, and fixing text layer displacement on PDFs with non-zero MediaBox origins.

Key Highlights

  • Fixed Python API ignoring the language parameter - now correctly maps to OcrOptions and handles +-separated language codes
  • Fixed tesseract_timeout defaulting to 0 causing immediate timeouts - now defaults to None (180-second plugin timeout)
  • Fixed OCR text layer displacement on PDFs with non-zero MediaBox origins (e.g. JSTOR or cropped PDFs)
  • Restored image overlay support (--image) for hocrtransform tool with fpdf2 renderer
  • Updated Docker Alpine base image to 3.23

New Features

  • Restored image overlay support (--image) for hocrtransform tool enabling sandwich PDF output with fpdf2 renderer

Full Release Notes

- Fixed Python API ignoring the ``language`` parameter, always defaulting to
  ``eng``. The API now correctly maps ``language`` to OcrOptions ``languages``
  and splits ``+``-separated codes (e.g. ``eng+deu``) to match CLI behavior.
  {issue}`1640`
- Fixed Python API producing empty OCR output because ``tesseract_timeout``
  defaulted to 0, causing Tesseract to time out immediately. The default is
  now ``None``, falling back to the plugin's 180-second timeout. {issue}`1636`
- Fixed OCR text layer displacement on PDFs with non-zero MediaBox origins
  (e.g. JSTOR or cropped PDFs). The coordinate transformation matrix is now
  always computed, not skipped when rotation is zero. {issue}`1630`
- Restored image overlay support (``--image``) for the hocrtransform tool,
  enabling sandwich PDF output with the fpdf2 renderer. {issue}`1634`
- Docker: updated Alpine base image to 3.23.
- Documentation restructured into per-major-version release notes files.
- Release process improvements.