sphinx-contrib / openapi

OpenAPI (fka Swagger) spec renderer for Sphinx.
https://sphinxcontrib-openapi.readthedocs.io
BSD 2-Clause "Simplified" License
111 stars 81 forks source link

ERROR: Unknown directive type "openapi" #126

Closed sachin-suresh-rapyuta closed 2 years ago

sachin-suresh-rapyuta commented 2 years ago

I have installed openapi extension using:

pip install sphinxcontrib-redoc.

In one of my .rst file, I have:

.. openapi:: specs/openapi.yaml.

When I make html, build fails with:

ERROR: Unknown directive type "openapi".

.. openapi:: specs/openapi.yaml

My Python version:

$ python3 --version
Python 3.8.10

$ pip list
sphinxcontrib-openapi         0.7.0

UPDATE:

I also uninstalled sphinxcontrib-redoc and installed using pip3. When I build I get no errors. But I don't get the APIs rendered in my HTML.

I am using openapi: 3.1.0.