• Ethan Furman's avatar
    Issue #19030: final pieces for proper location of various class attributes… · b0c84cda
    Ethan Furman yazdı
    Issue #19030: final pieces for proper location of various class attributes located in the metaclass.
    
    Okay, hopefully the very last patch for this issue.  :/
    
    I realized when playing with Enum that the metaclass attributes weren't always displayed properly.
    
    New patch properly locates DynamicClassAttributes, virtual class attributes (returned by __getattr__ and friends), and metaclass class attributes (if they are also in the metaclass __dir__ method).
    
    Also had to change one line in pydoc to get this to work.
    
    Added tests in test_inspect and test_pydoc to cover these situations.
    b0c84cda
pydoc.py 98.6 KB