Hi,
I use properties with typehints in Sphinx.
To handle typehints I use sphinx-autodoc-typehints.
It seems that sphinx handles properties as methods. This produces strange
results in the output.
For instance, for a property lb, which has a getter and setter, sphinx
documents as:
lb
the variable lower bound
*Return type* float
The expression return type here is wrong. I think that the correct output
for a property, specially for one that is not readonly should be:
lb
the variable lower bound
*Type* float
The python code for this part is:
@property
def lb(self) -> float:
"""the variable lower bound"""
return self.model.solver.var_get_lb(self)
@lb.setter
def lb(self, value: float) -> None:
self.model.solver.var_set_lb(self, value)
Cheers,
Haroldo
--
You received this message because you are subscribed to the Google Groups
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sphinx-users.
For more options, visit https://groups.google.com/d/optout.