[issue19030] inspect.getmembers and inspect.classify_class_attrs mishandle descriptors
Ethan Furman
report at bugs.python.org
Mon Oct 14 18:10:10 CEST 2013
Ethan Furman added the comment:
Updated and renamed the DynamicClassAttribute tests, and discovered that classify_class_attrs is not handling instance portion correctly.
class Meta(type):
def __getattr__(self, name):
if name == 'ham':
return 'spam'
return super().__getattr__(name)
class VA(metaclass=Meta):
@types.DynamicClassAttribute
def ham(self):
return 'eggs'
We should see both eggs and spam, but only eggs is showing up.
----------
assignee: -> ethan.furman
resolution: fixed ->
stage: committed/rejected ->
status: closed -> open
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue19030>
_______________________________________
More information about the Python-bugs-list
mailing list