Message 162026 - Python tracker (original) (raw)

This is doubtless a result of the way the class namespace scope is handled, coupled with the fact that in Python3 list comprehensions have a local scope. The class scope is a somewhat unique beast. I agree that this is unfortunate, but I have a feeling that doing anything about it is distinctly non-trivial.