[Zope] Re: upgrade 2.5.1 to 2.7.5 causes error in product code

Florent Guillaume fg at nuxeo.com
Wed Aug 31 10:01:53 EDT 2005


John Schinnerer wrote:
> Hello,
> 
> Thanks Tres, looks like zope 2.7.5/python 2.3.5 is triggering a genuine
> full-blown error on my code
> 
> python:here.sponsors[0] != ''
> 
> if the tuple is empty, whereas 2.5.1/2.1.3 must have been returning
> some equivalent of boolean 'false' when the tuple was empty.
> 
> Now I do this
> 
> python: (here.sponsors) and (here.sponsors[0] != '')
> 
> and it works again.
> The second condition may be redundant now I suppose...?
> 

Yes in earlier Zopes, changing a lines property in the ZMI to empty still 
resulted in ('',) instead of (). This has been fixed since.

Florent

-- 
Florent Guillaume, Nuxeo (Paris, France)   CTO, Director of R&D
+33 1 40 33 71 59   http://nuxeo.com   fg at nuxeo.com


More information about the Zope mailing list