pombreda / xhtml2pdf

Automatically exported from code.google.com/p/xhtml2pdf
GNU General Public License v2.0
0 stars 0 forks source link

AttributeError: 'NoneType' object has no attribute 'err' (c.err += 1) #47

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Not sure. Problem happened once, and a refresh fixed it. (See below)

What is the expected output? What do you see instead?
Expected output is a PDF, but instead I received this:

raceback (most recent call last):

 File "/usr/lib/python2.5/site-packages/django/core/handlers/base.py", line 
92, in get_response
   response = callback(request, *callback_args, **callback_kwargs)

 File "/home/corky/live/internal/sales/views/printer.py", line 58, in 
print_sale
   return write_pdf(template_list, extra, attachment)

 File "/home/admin/live/internal/../internal/utility.py", line 80, in 
write_pdf
   html.encode("UTF-8")), result, link_callback=fetch_resources)

 File "/usr/lib/python2.5/site-packages/pisa-3.0.30-
py2.5.egg/sx/pisa3/pisa_document.py", line 212, in pisaDocument
   c.err += 1

AttributeError: 'NoneType' object has no attribute 'err'

--------------------

Upon refresh, the error did not happen. This doesn't make much sense as 
nothing from the database was changed. I can't think of what would "fix" it 
after simply trying again.

What version of the product are you using? On what operating system?

pisa-3.0.30 on Ubuntu Intrepid.

Original issue reported on code.google.com by bart.ci...@gmail.com on 10 Aug 2009 at 2:15

GoogleCodeExporter commented 9 years ago
Some time ago Pisa AKA XHTML2PDF has been rereleased under the completely free 
Apache License. Since I personally don't have the time and resources to 
continue the project like before I would kindly ask you to fork the project on 
GitHub and add your patches etc. Maybe someone likes to create a new unified 
version and publish it on PyPI. If you need more help on this get in contact 
with me or write to the XHTML2PDF mailing list. Thank you all very much for 
your effort!

Project on GitHub:
http://github.com/holtwick/xhtml2pdf

Original comment by dirk.holtwick on 23 Aug 2010 at 5:27