Has anyone gotten this error from qvm-convert-pdf?
Invalid image dimensions
I’m trying to sanitize a PDF using qvm-convert-pdf, but it fails (without outputting the sanitized pdf) with this error. I don’t know what to do 
user@host:~$ qvm-convert-pdf some-file.pdf
Sending file to Disposable VM...
some-file.pdf...fail
error: some-file.pdf: Invalid image dimensions
Total Sanitized Files: 0/1
user@host:~$
Anyone know what causes this, and what is the workaround?
1 Like
As far as I can tell, this is the code that’s responsible for this error:
1 Like
Update: I also tried using dangerzone in a DispVM, and it also failed with the pdf file with the following error
Unknown error code '125'e[0m
Marking doc Mf39Kl as 'failed'
1 Like
I got them to work in dangerzone by increasing the “private storage” disk space of the DispVM from 2 GB to 20 GB.
The PDF files that failed are about 10 MB to 20 MB each.
I’m guessing I would have to do the same for the DispVM to fix this issue in Qubes.
2 Likes
Okay, can you confirm the increased private storage also works with qvm-convert-pdf?
That “Invalid image dimensions” error is usually a sign that the PDF pages have an unusual DPI or size that the Qubes sanitizer doesn’t like. Before diving too deep into the backend logs, you might want to try re-exporting the images or compressing the PDF slightly to see if standardizing the dimensions helps.
If you just need to get it done and aren’t dealing with super sensitive info, I sometimes use Image to PDF Converter | TheToolApp to flatten or re-align images before trying the qvm-convert-pdf tool again. It’s often easier than trying to troubleshoot the exact dimension limit in the DispVM scripts.
1 Like