[reportlab-users] Hi Help on Install, get errors.

John Pywtorak reportlab-users@reportlab.com
Mon, 26 Apr 2004 15:42:56 -0700


Have your tried running some of the test individually?

=46rom what I can see colors is equal to None and so you see the error, thi=
s is=20
easily replicated by the following which I did in ipython
In [2]: foo =3D None
In [3]: foo.bar()
=2D------------------------------------------------------------------------=
=2D-
AttributeError                            Traceback (most recent call last)

/home/jpywtora/devel/<console>

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

This does not mean your complete reportlab install is bad, but maybe not=20
complete?  If, I remember correctly I could not get all the tests to pass,=
=20
however my install works.

Johnny P

On Monday 26 April 2004 01:15 pm, Danie Brink wrote:
> Hi All,
>
> I read the manual and it told me to put it in the python path. That did
> not work, then I installed it using :
>     python setup.py build
> and
>     python setup.py install
>
> Ran the ./test/runAll.py and it gave me errors not finding renderPM,
> which I downloaded and installed using the same technique. Once again I
> tested an had a lot of errors regarding fonts, gifs, etc. I finally
> realized the software only installed the py files and not the other
> files. I then copied these into the corresponding install directories
> and again ran ./test/runAll.py. It gave me this output which, for the
> live of me I can not figure out why. It can not find the procedures
> listed in ./lib/colors.py, they are there and they should work, I Think.
>
> :-(
>
> Can anybody help me with this one ?. I am running SuSE 9.0 and Python
> 2.3.
>
> linux:/usr/lib/python/site-packages/reportlab/test # python ./runAll.py
> .........................................................................=
=2E.
>..........................................EEEEEE..............
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> ERROR: Test color2bw function on all named colors.
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "./test_lib_colors.py", line 43, in test0
>     cols =3D colors.getAllNamedColors().values()
> AttributeError: 'NoneType' object has no attribute 'getAllNamedColors'
>
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> ERROR: Test colorDistance function.
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "./test_lib_colors.py", line 53, in test1
>     cols =3D colors.getAllNamedColors().values()
> AttributeError: 'NoneType' object has no attribute 'getAllNamedColors'
>
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> ERROR: Test toColor function on half a dozen ways to say 'red'.
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "./test_lib_colors.py", line 62, in test2
>     allRed =3D [colors.red, [1, 0, 0], (1, 0, 0),
> AttributeError: 'NoneType' object has no attribute 'red'
>
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> ERROR: Test roundtrip RGB to CMYK conversion.
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "./test_lib_colors.py", line 75, in test3
>     rgbCols =3D colors.getAllNamedColors().items()
> AttributeError: 'NoneType' object has no attribute 'getAllNamedColors'
>
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> ERROR: Construct CMYK instances and test round trip conversion
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "./test_lib_colors.py", line 93, in test4
>     rgbCols =3D colors.getAllNamedColors().items()
> AttributeError: 'NoneType' object has no attribute 'getAllNamedColors'
>
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> ERROR: List and display all named colors and their gray equivalents.
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "./test_lib_colors.py", line 113, in test5
>     canvas =3D reportlab.pdfgen.canvas.Canvas('test_lib_colors.pdf')
> AttributeError: 'NoneType' object has no attribute 'pdfgen'
>
> ----------------------------------------------------------------------
> Ran 137 tests in 103.628s
>
> FAILED (errors=3D6)
>
> Any help will be much appreciated.
>
> Danie Brink.