sphinx/tests/roots/test-ext-autodoc/target/instance_variable.py
Takeshi KOMIYA 9a9433e403 Fix #9283: autodoc: failed to build doc for attribute not commented
Autoattribute directive should check the existence of instance attribute
that is defined inside __init__() but not having comments before
accessing it.
2021-05-30 19:48:11 +09:00

12 lines
279 B
Python

class Foo:
def __init__(self):
self.attr1 = None #: docstring foo
self.attr2 = None #: docstring foo
class Bar(Foo):
def __init__(self):
self.attr2 = None #: docstring bar
self.attr3 = None #: docstring bar
self.attr4 = None