[Thuban-list] Thuban CVS version: cannot classify on incomplete data - unsupported operand type(s) for -: 'NoneType' and 'NoneType'

Bernhard Herzog bh at intevation.de
Tue Mar 23 16:27:38 CET 2004


"Moritz Lennert" <mlennert at club.worldonline.be> writes:

>   File "/usr/lib/thuban/Thuban/UI/graph.py", line 50, in __init__
>     self.data = [ (d-mnd)/(mxd-mnd) for d in data ]
> TypeError: unsupported operand type(s) for -: 'NoneType' and 'NoneType'

The Table objects return None for NULL values in the database.  It
appears that the code in graph.py doesn't handle that case.  In this
particular case it's Daniel's code apparently, but I think some of out
code doesn't handle None correctly either.

I've create RT #2361 for this.


   Bernhard

-- 
Intevation GmbH                                 http://intevation.de/
Skencil                                http://sketch.sourceforge.net/
Thuban                                  http://thuban.intevation.org/



More information about the Thuban-list mailing list