Documentation for the Data Commons Python Client API is generated using Sphinx and hosted on readthedocs.org.
To generate documentation locally,
-
Autogenerate the API documentation using
sphinx-buildby running the following command in the root directory of this repository:sphinx-build -a docs/source docs/buildThis generates documentation as
.rstfiles from the Python docstrings of externally facing functions, classes and method in the API while ignoring test and example files. -
Navigate to the
docs/directory and executemake html. This will format the.rstfiles into.htmlfiles. -
Open
docs/build/html/index.htmlto access documentation.
Local documentation is not meant to be committe! Readthedocs will automatically build the documentation on a push to the Github repository.
- We use the
Sphix.ext.napoleonextension to parse Google style docstrings.