hypothesis / support-legacy

a place for tracking support-related work and projects
3 stars 0 forks source link

Some PDFs on iOS are showing as blank #178

Open mattdricker opened 3 years ago

mattdricker commented 3 years ago

We have received occasional reports of iOS devices not showing any text on a PDF in the Hypothesis viewer. See:

PDFs work perfectly fine using desktop browsers, but on iOS devices will render as below: Student Problem Alex LeGault (1)

PDF renders badly in iOS Safari and Chrome. Forcing a new OCR on the PDF using https://docdrop.org/ocr/ does not change behavior either.

I was able to get a working PDF in iOS by exporting the original to TIFF, then re-exporting as PDF, finally running the document through OCR again. Essentially creating an entirely new PDF from image.

To reproduce On an iOS device, open the following assignment: https://hypothesis.instructure.com/courses/92/assignments/1475

klemay commented 3 years ago

Support team:

mattdricker commented 3 years ago

Standalone PDF here: https://drive.google.com/file/d/1OA_mVftH02OlQ7m0iaagd9CQoTcM_RyU/view?usp=sharing

Confirmed in ipadOS (using https://mozilla.github.io/pdf.js/web/viewer.html) that opening above PDF using PDF.js without Hypothesis exhibits same behavior.

Found possibly relevant GH issues in PDF.js:

Relevant H Slack thread: https://hypothes-is.slack.com/archives/C2BLQDKHA/p1597945921007600