0

I have a Django project in which I generate PDF from HTML with PDFkit.

On my local machine I see the pdf just fine but on production machine the generated pdf page is a little bigger.

The html is correct and identical on both machines.

The OSes are the same (ubuntu 14.04).

Checked all the packages versions and they are the same.

My pdf generating code is:

options = {'page-size': 'A2', 'margin-top': '0in', 'margin-right': '0in', 'margin-bottom': '0in', 'margin-left': '0in'}
pdf_location = '/...../executive_summary.pdf'
pdfkit.from_string(my_template.render(context_dict), pdf_location, options=options, css='/....../executive_summary.css')

wkhtmltopdf is the latest

pdfkit==0.6.1

The screenshots are attached. Where else can be the problem?

enter image description here

enter image description here

alexarsh
  • 5,123
  • 12
  • 42
  • 51

0 Answers0