[Zope3-dev] Re: SVN: Zope3/branches/3.3/ - fix for issue 517: intid might generate long instead of int which conflicts with btrees

Florent Guillaume fg at nuxeo.com
Sat Jun 17 15:54:56 EDT 2006


Christian Theune wrote:
> Log message for revision 68700:
> --- Zope3/branches/3.3/src/zope/app/intid/__init__.py	2006-06-17 03:29:43 UTC (rev 68699)
> +++ Zope3/branches/3.3/src/zope/app/intid/__init__.py	2006-06-17 04:10:29 UTC (rev 68700)
> @@ -47,7 +47,10 @@
>      """
>      implements(IIntIds)
>  
> -    _v_nextid = None
> +    _v_nextid = None   
> +    
> +    # Used for testability of random function
> +    __randint__ = random.randint

You should avoid such __names__, they are supposed to be reserved. Here, 
__randint would have been quite enough I believe.

Florent

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


More information about the Zope3-dev mailing list