Skip to content

autosummary does not create the description for descriptor attributes #1444

@shimizukawa

Description

@shimizukawa

For example, I want to document the following:

#!python

# MyModule.py

class D(object):
    """Descriptor class
    """

    def __get__(self, instance, owner):
        return 1

    def __set__(self, instance, value):
        pass

class A(object):
    """My Class
    """

    #: Descriptor attribute
    abc = D()

And I create the following RST file:

#!

.. module:: MyModule

.. autoclass:: A
    :members:

    .. autosummary::

        abc

autosummary creates table with the following description for attribute abc:

int(x=0) -> int or long

But in this case I want to see:

Descriptor attribute


Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions