Stefan Behnel added the comment:

One more thing: the fact that the lookup does not propagate exceptions leaves 
some space for ambiguity. If, in a chain of MRO lookups, one would fail and a 
later one would succeed, is it correct to keep trying? What if the first 
failure actually failed to see an otherwise existing attribute in that class? 
We simply can't know because the lookup failed for *some* reason.

I think, the only way to really avoid that ambiguity would be to allow 
_PyType_Lookup() to raise exceptions, and to make it fail on the first error. 
I've created issue 31465 for this.

----------

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

Reply via email to