PDF Extractor Returns Empty? Dev Shares Zero-Dependency Triage Tool

simply_prashant · reddit · 2026-07-30

A developer discovered that PDF extractors returning empty strings often means the file is purely scanned images, not corrupted.

To prevent this silent failure, the author built a standard-library-only PDF triage script. It parses the underlying object structure to classify files accurately (e.g., TEXT, SCANNED, FORM) and recommends the appropriate next steps like OCR.

The post also details development pitfalls, such as false positives from embedded fonts and table detection edge cases, and provides a one-liner to install the tool as a skill for AI coding agents like Claude Code and Cursor.

Original post →

More from coding & agent

coding & agent channel →