Skip to content

Commit

Permalink
t
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakski committed Nov 21, 2024
1 parent 79228d4 commit 5d1f8ff
Show file tree
Hide file tree
Showing 6 changed files with 60 additions and 10 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
strategy:
matrix:
python: ["3.10", "3.11"]
env: ["1", "2", "3"]
env: ["1", "2", "3", "4", "5"]
steps:
- name: Cache dependencies
uses: actions/cache@v2
Expand All @@ -36,6 +36,6 @@ jobs:
python-version: ${{ matrix.python }}

- name: Run tests
run: ./ci.sh test "$ENV"
run: ./ci.sh test "$ENV_NUMBER"
env:
ENV: ${{ matrix.env }}
ENV_NUMBER: ${{ matrix.env }}
12 changes: 12 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
# [1.1.2] - 2024-11-13
### Added
- Tests for Sphinx 7 and 8

### Fixed
- Missing compose_all in ruamel.yaml 0.18

### Removed
- Tests for Sphinx 3. `ImportError: cannot import name 'Union' from 'types'`
for Python above 3.9. Version constraint is left for compatibility, but support
for Sphinx 3 will be dropped in future versions.

# [1.1.2] - 2024-11-13
### Changed
- Support for ruamel.yaml 0.18.x
Expand Down
13 changes: 11 additions & 2 deletions ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ EOF

# shellcheck disable=SC2034
update_requirements_cmd() {
declare i
declare selected=${1:-} i
declare -a env1 env2 env3 env4
# Some contrib extensions don't specify required Sphinx version in dependencies, yet fail on setup
env1=(
Expand All @@ -36,12 +36,21 @@ update_requirements_cmd() {
"sphinxcontrib-qthelp<=1.0.3"
)
env2=("Sphinx>=5,<6")
# ruamel.yaml deprecated compose_all in 0.18
env3=("Sphinx>=5,<6" "ruamel.yaml>=0.17,<0.18")
for i in {1..4}; do
env4=("Sphinx>=6,<7")
env5=("Sphinx>=7,<8")
for i in {1..5}; do
if [ -n "$selected" ] && [ "$i" != "$selected" ]; then
continue
fi
declare -n constraints="env${i}"
python3 -m venv --clear venv
./venv/bin/pip install ".[test]" "${constraints[@]}"
./venv/bin/pip freeze --exclude "sphinxcontrib-autoyaml" >"tests/requirements-${i}.txt"
if [ "$selected" = "$i" ]; then
break
fi
done
}

Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ classifiers = [
"License :: OSI Approved :: MIT License",
"Topic :: Documentation",
]
requires-python = ">=3.10"
requires-python = ">=3.6"
dependencies = [
"Sphinx>=4",
"Sphinx>=3.5.1",
"ruamel.yaml>=0.16.12",
]

Expand Down
6 changes: 3 additions & 3 deletions tests/requirements-4.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
alabaster==1.0.0
alabaster==0.7.16
babel==2.16.0
certifi==2024.8.30
charset-normalizer==3.4.0
docutils==0.21.2
docutils==0.19
flake8==7.1.1
idna==3.10
imagesize==1.4.1
Expand All @@ -18,7 +18,7 @@ ruamel.yaml==0.18.6
ruamel.yaml.clib==0.2.12
six==1.16.0
snowballstemmer==2.2.0
Sphinx==8.1.3
Sphinx==6.2.1
sphinx-testing==1.0.1
sphinxcontrib-applehelp==2.0.0
sphinxcontrib-devhelp==2.0.0
Expand Down
29 changes: 29 additions & 0 deletions tests/requirements-5.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
alabaster==0.7.16
babel==2.16.0
certifi==2024.8.30
charset-normalizer==3.4.0
docutils==0.21.2
flake8==7.1.1
idna==3.10
imagesize==1.4.1
Jinja2==3.1.4
MarkupSafe==3.0.2
mccabe==0.7.0
packaging==24.2
pycodestyle==2.12.1
pyflakes==3.2.0
Pygments==2.18.0
requests==2.32.3
ruamel.yaml==0.18.6
ruamel.yaml.clib==0.2.12
six==1.16.0
snowballstemmer==2.2.0
Sphinx==7.4.7
sphinx-testing==1.0.1
sphinxcontrib-applehelp==2.0.0
sphinxcontrib-devhelp==2.0.0
sphinxcontrib-htmlhelp==2.1.0
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==2.0.0
sphinxcontrib-serializinghtml==2.0.0
urllib3==2.2.3

0 comments on commit 5d1f8ff

Please sign in to comment.