Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fix autodoc in library doc builds #624

Closed
@tannewt

Description

@tannewt

These repos have docs that may technically pass but the autodoc portion fails. This is usually due to a library not being mocked out. To fix it, a line must be added to conf.py to tell sphinx to mock out specific modules. Here is the line from the latest cookicutter's conf.py:

# Uncomment the below if you use native CircuitPython modules such as
# digitalio, micropython and busio. List the modules you use. Without it, the
# autodoc module docs will fail to generate with a warning.
# autodoc_mock_imports = ["adafruit_bus_device", "micropython"]

Copy these four lines, uncomment the fourth and adjust the list until the sphinx build includes the autodocs.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions