julihoh / pdf_annotation_fix

Fixes macOS Preview garbled annotations
MIT License
374 stars 19 forks source link

Header error parsing pdf file in web app #4

Open rkworden opened 2 years ago

rkworden commented 2 years ago

Opening a pdf that was annotated in Big Sur. Upon uploading the document and pressing "Save Recovered", I get this error:

unable to parse pdf document

Caused by:
    Invalid file header

Shoot me your email address and I will forward the actual document to you

Screen Shot 2022-03-08 at 1 53 51 PM

Many thanks

.

julihoh commented 1 year ago

I'm not sure what could cause this. There is unfortunately not much I can do about it. The tool relies on https://crates.io/crates/lopdf for pdf parsing. If that fails, the tool can't do much.

Regardless, I have updated the pdf parser to the latest version. If you're lucky, this fixes your issue, but not promises. I suggest you try again using the web app (the update should be live already).