Irit Katriel <iritkatr...@gmail.com> added the comment:

Serhiy's patch is modifying a different part of this system - he changes the 
Exception object's SetContext to break cycles when they are first created. 
Dennis and I targeted the place where an exception is about to be raised and it 
gets a __context__ that may contain a cycle already.

I think it's possible to take the more drastic step of preventing the cycles 
being created altogether, as Serhiy did. I would prefer that we raise an 
exception and refuse to create the cycle rather than try to fix it.  I don't 
think we can come up with a meaningful fix to what is, really, a user bug.

In any case, at the moment we have a situation where user bugs (like 
Issue40696) can cause the interpreter to hang, and if we need more time to 
decide about the full strategy, we should at least prevent the hang.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue25782>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to