[issue6717] Some problem with recursion handling

Antoine Pitrou report at bugs.python.org
Thu Apr 12 18:31:50 CEST 2012


Antoine Pitrou <pitrou at free.fr> added the comment:

> It's catching the exception when it invokes x, but the recursion
> enforcement should happen at a method prolog, including at the
> invocation of g.  Therefore if we're at or beyond the recursion limit
> when invoking the trace handler the limits should still be enforced
> and that should be the same as the trace handler raising.

That's where 3.x is different: 3.x temporarily bumps up the recursion
limit a bit when it is first reached, in order to let various cleanup
handlers run as intended. This is a nice thing in the general case, but
means it can degenerate in more involved or desperate cases.

(although here it's not clear to me why a second recursion error occurs
after the first one)

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6717>
_______________________________________


More information about the Python-bugs-list mailing list