How do I configure Read the Docs to use sphinx-autodoc-annotation?
Question: I'm using sphinx-autodoc-annotation to read the function annotations in my
Python code and use that to generate the appropriate expected argument types
and return types. It's working great on my local machine, but I had to `pip
install sphinx-autodoc-annotation` of course.

I'm trying to generate the same documentation using [Read the
Docs](https://readthedocs.org/), but it gives me an error:

    
    
    Could not import extension sphinx_autodoc_annotation (exception: No module named sphinx_autodoc_annotation)
    

Is it possible to configure Read the Docs to work with sphinx-autodoc-
annotation, and if so, how do I make it work?


Answer: Activate the _Install Project_ option for your Read the Docs project.

If the option is activated, Read the Docs will try to execute `setup.py
install` on your package (see: [RtD docs](https://read-the-
docs.readthedocs.io/en/latest/builds.html#understanding-what-s-going-on)). In
`setup.py`, you can install packages as specified in your [requirements
file](https://pip.readthedocs.io/en/1.1/requirements.html). Have a look at the
[source code of the Flask-MongoRest project](https://github.com/closeio/flask-
mongorest) for an example.

Add `sphinx-autodoc-annotation` as the only requirement to your
`requirements.txt` file.

