There are a lot of different ways of generating pdfs from a django webpage in python2. The most clean, probably, is pisa and reportlab. These do not work for python3 though.
I have tried pydf in Python3, its working fine.
pip install python-pdf
For python2 use pip install python-pdf==0.30.0
python2
pip install python-pdf==0.30.0
Documentation https://github.com/tutorcruncher/pydf