Skip to content

Properties are shown as var  #276

@johann-petrak

Description

@johann-petrak

The generated documentation for a property:

@property
def weight(self) -> int:
...

is shown as "var weight : int" but it would be more useful if the fact that this is a property would get shown, e.g.
"property weight: int" as the Sphinx generator does.

This is also shown under the header "Instance variables" which is not exactly right.

Also, if there is a separate setter for the property:

@weight.setter
def weight(self, weight):
...

this is not reflected in the documentation, so there is no way to see from the documentation if the property can only be read or set as well. Only the docstring of the getter method is included in the generated documentation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Hacktoberfesthttps://hacktoberfest.digitalocean.comenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions