Skip to content

Commit

Permalink
Fix ReadTheDocs config for Poetry (#1663)
Browse files Browse the repository at this point in the history
  • Loading branch information
RobbeSneyders committed Mar 3, 2023
1 parent 6d8c297 commit c257f04
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 11 deletions.
20 changes: 13 additions & 7 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,16 @@ version: 2
sphinx:
configuration: docs/conf.py

python:
version: 3.7
install:
- method: pip
path: .
extra_requirements:
- docs
build:
os: "ubuntu-22.04"
tools:
python: "3.8"
jobs:
post_create_environment:
# Install poetry
- pip install poetry
# Tell poetry to not use a virtual environment
- poetry config virtualenvs.create false
post_install:
# Install dependencies with 'docs' dependency group
- poetry install --with docs
8 changes: 4 additions & 4 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,12 @@
# |version| and |release|, also used in various other places throughout the
# built documents.
#
import connexion
from importlib.metadata import version

# The short X.Y version.
version = connexion.__version__.rsplit('.', 1)[0]
# The full version, including alpha/beta/rc tags.
release = connexion.__version__
release = version('connexion')
# The short X.Y version.
version = release.rsplit('.', 1)[0]

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down

0 comments on commit c257f04

Please sign in to comment.