qrenderer.exclude_functions

exclude_functions(spec)

Exclude the methods of a class or functions of a module from documentation

When a class has deprecated method(s) or a module has deprecated function(s), we may want to exclude them from the documentation. Use this function in your _renderer.py file to specify them.

Parameters

spec : dict[str, str | Sequence[str]]

Parent object path and the function(s) to exclude. The object path is as shown on the API page and not the canonical path. e.g.

Examples

If we are documenting ClassA with the deprecated methods marked as shown below.

class ClassA:
    def func_a(self):  # deprecated
        return "a"

    def func_b(self):
        return "b"

We would use this to exclude the functions from being listed in the documentation.

from qrenderer import exclude_functions

exclude_functions({
    "package.ClassA": "func_a",
})