You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We know you're not supposed to pass a stirng into zope.interface.implements, but try the following:
>>> from zope.interface import implements
>>> class Foo(object):
... implements('foo')
the prompt will hang for a while. Then we get this error:
File "/home/faassen/buildout/grok-eggs/eggs/tmpxXgh8b/zope.interface-3.4.0a1-py2.4-linux-i686.egg/zope/interface/declarations.py", line 1370, in _normalizeargs
File "/home/faassen/buildout/grok-eggs/eggs/tmpxXgh8b/zope.interface-3.4.0a1-py2.4-linux-i686.egg/zope/interface/declarations.py", line 1370, in _normalizeargs
File "/home/faassen/buildout/grok-eggs/eggs/tmpxXgh8b/zope.interface-3.4.0a1-py2.4-linux-i686.egg/zope/interface/declarations.py", line 1366, in _normalizeargs
RuntimeError: maximum recursion depth exceeded in cmp
Perhaps something can be done to prevent this infinite recursion. Not urgent, but would be nice as this is rather surprising.
The text was updated successfully, but these errors were encountered:
The variety of things that _normalizeargs accepts makes this a complicated problem, especially since it's involved at import time and we don't want to slow that down. Perhaps a simple assert not isinstance(sequence, str) handles this well enough?
In https://bugs.launchpad.net/zope.interface/+bug/113672, @faassen reported
The text was updated successfully, but these errors were encountered: