qrenderer.exclude_attributes
exclude_attributes(spec)Exclude the parameters of functions/class in the documentation
When a function has a deprecated attribute, we may want to exclude it from the documentation. Use this function in your _renderer.py file to specify them.
Parameters
Examples
Assuming we are documenting ClassA and ClassB with the deprecated attributes marked as shown below.
class ClassA:
a: int = 1
b: str = "rock"
c: bool = False # deprecated
class ClassB:
a: int = 1
b: str = "paper" # deprecated
@property
def value(self): # deprecated
return 1We would use this to exclude the attributes from the documentation.
from qrenderer import exclude_attributes
exclude_attributes({
"package.ClassA": "c",
"package.ClassB": ("b", "value")
})