[reportlab-users] Error: test_pdfgen_general.py

Andy Robinson andy at reportlab.com
Tue May 23 17:24:29 EDT 2006

> FAILED (errors=1)
> I'm on W2k SP4 and Python 2.4.2. I don't have PIL installed.
> Any help?

After inspecting the code I think it's that you don't have PIL
installed; everyone here has been using PIL for so long that we have 
never thought to run the tests without it.  I just renamed my PIL
directory and get the same thing.

Sorry about this but it's a spurious test failure; you should have a lot 
of other PDFs which did work.  And I recommend installing PIL as sooner 
or later you will want to use a bitmap in a PDF.

If you don't want to install it, add the line below  "(w, h) = (144, 
10)" after line 696 and the test should complete.

     for i in range(5):
         if haveImages:
             (w, h) = c.drawImage(gif, (1.5 + i)*inch, 3*inch)
             (w, h) = (144, 10)
             c.rect((1.5 + i)*inch, 3*inch, 110, 44)

I checked this change in.  With it, the test suite still generates some 
failure messages but they all say clearly that PIL being missing is the 

Best Regards,

Andy Robinson

More information about the reportlab-users mailing list