PDF broke after bench update v15

Hi
I am on v15 working on vm virtualbox
i did a bench update
now i get this error while trying to print PDF

Invalid wkhtmltopdf version

PDF generation may not work as expected.

Please contact your system manager to install correct version.
Correct version : wkhtmltopdf 0.12.x (with patched qt).

could somebody help me as to how i should update the same
Please help
Thanks and Regards
Hemanth

Hi,

Check the version by typing: wkhtml2pdf -V

wkhtml2pdf may be downloaded from here:

https://wkhtmltopdf.org/downloads.html Install the one that is appropriate for the OS.

1 Like

This worked for me in ubuntu 22.04

wget https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6.1-2/wkhtmltox_0.12.6.1-2.jammy_amd64.deb

sudo apt install -f ./wkhtmltox_0.12.6.1-2.jammy_amd64.deb

I ran the command sudo su frappe-user
I navigated to cd /home/frappe-user/frappe-bench

I tried to run this command : wkhtml2pdf -V

But it said : wkhtml2pdf: command not found

What am I missing?

Edit :
The command you mentioned didn’t work for me, but this one did : wkhtmltopdf --version

Hmm, here both commands returns:

wkhtmltopdf 0.12.6.1 (with patched qt)

It may help to say what the OS is in vbox.

Hi
Thanks for the Tip
I updated using the code you had suggested
Now the PDF works fine, but its printing an additional blank page
The first page is the actual print that comes fine. But along with it a second blank page gets printed
my Letter head image size is 900 x 60 pixells
any idea to remove the second page
Thanks and Regards
Hemanth

If you’re using a custom print format, try to reduce the margin and padding of the DOM elements you used.