"Version incompatibility" "incorrect file version" when opening pdf

The pdf editing functionality, which I really enjoyed last year, seems broken.

I have a big pdf file that I’d like to edit with LibreOffice. However, when I open it I get the “Version incompatibility” “Incorrect file version” (these appear in two lines) error.

Investigating a little further, I created two test pdf files from tiny, one-line documents, one with MSFT Word (version 16.56 (21121100)) and the other with Google Docs. I also updated LibreOffice from version to version

Using File-open in either of these versions of LibreOffice generates the “Version incompatibility” “Incorrect file version” error in both test pdf files. See the attached files, which I have renamed with ‘odg’ extensions so that I can upload them.

Using macOS Big Sur ver. 11.6 (20G165).

Simple - Google Docs copy.odg (16.1 KB)
Simple - Microsoft Word copy.odg (14.8 KB)

When renamed as .pdf files (and opened in PDF-XChange editor in Windoze), the first (Google Docs) opens fine.

The second (MS) opens fine but with “Errors detected in the XREF table”.

I can open neither in LO Draw without the “Version incompatibility” error.

EDIT: After more investigation, it seems Adobe Reader will identify the error and open the pdf without notifying the user :frowning:

but PDF-XChange will identify the error and will notify the user with the “Errors detected in the XREF table” warning.

Both readers will allow saving a corrected version of the file.

It looks as if both Google Docs & Word create invalid pdf file from your input.

Both files open without error notification with Okular PDF reader on my Fedora 35/KDE workstation. Both give the error with Draw. Gimp opens both files.

I tried to have a look with an hexadecimal editor. It reports PDF 1.6, but many parts of the file are compressed (?) giving a binary flow which needs to be expanded before being used (normally PDF is encoded as a kind of postfix Polish language, a bit like PostScript from which it derives). This may be where the issue lies.


Agreed - 1.6 here too. The “pdf” structure seems to be broken.

Thanks for your deep analysis, folks

It pains me to say this because it’s much better when code adheres to standards, but if “Google Docs & Word create invalid pdf files” as you say, then it seems that LibreOffice should open invalid pdf files like these with a warning, rather than raise the fatal “Version incompatibility” “incorrect file version” error.

I should note that these pdf files were created by printing, opening in Preview and then saving the file. Google Docs & Word documents can both be saved directly as pdf. I don’t have time to do that now.


Writer can export directly to PDF.

Note that that likely explains, and moves the “who creates the invalid PDFs” from “Google Docs & Word” to “your virtual PDF printer” (reported as “Quarts PDFContext” in Adobe Reader).

1 Like

The error is shown from pdfi::checkEncryption, because (it thinks) there’s an incompatible encryption used.

You might want to file a bug report.

1 Like

Thanks Mike and everyone else.
Unfortunately, I don’t have experience filing LibreOffice bug reports and don’t have time now. Could someone else take that on please?