Repository: svenevs/exhale (language: python)

Issue:
Problem with Sphinx 7
## Problem

Exhale fails to run with sphinx 7 because the requirements does not allow the latest exhale version to be installed:

> install_requires =
    # From breathe==4.32.0
    Sphinx>=3.0,<7

For this reason `pip` installs an older exhale version 0.2.4 which is incompatible with sphinx 7.

## Solution

Allow exhale 0.3.6 to run with sphinx 7. Tested and works (sphinx==7.2.6).

Fixed by #200 
Update dependencies according to breathe==4.35.0
### Change

* Breaking: Remove support of sphinx 3.x
* Update dependencies according to breathe==4.35.0

Fixes  #202


Discussion / hints:

Fix patch:
diff --git a/README.rst b/README.rst
index 7b9237f..ec243db 100644
--- a/README.rst
+++ b/README.rst
@@ -133,6 +133,8 @@ Exhale Version Compatibility with Python, Sphinx, and Breathe
 +----------------+----------------+----------------+-----------------+
 | Exhale Version | Python Version | Sphinx Version | Breathe Version |
 +================+================+================+=================+
+| 0.3.7          | >=3.8          | >=4.3.2        | >=4.33.1        |
++----------------+----------------+----------------+-----------------+
 | 0.3.2 -- 0.3.6 | >=3.7          | >=3.0,<5       | >=4.32.0        |
 +----------------+----------------+----------------+-----------------+
 | 0.3.0          | >=3.6          | >=3.0,<5       | >=4.32.0        |
diff --git a/docs/changelog.rst b/docs/changelog.rst
index 71719be..0ceb2cc 100644
--- a/docs/changelog.rst
+++ b/docs/changelog.rst
@@ -5,6 +5,19 @@ Changelog
    :local:
    :backlinks: none
 
+v0.3.7
+----------------------------------------------------------------------------------------
+
+- Update packaging requirements (:pr:`204`).  Exhale will be less restrictive in its
+  dependency requirements:
+
+    - Python 3.8+ (3.7 is EOSL).
+    - Breathe>=4.33.1.
+    - Sphinx>=4.3.2.
+    - See :issue:`191` for more information.
+- Miscellaneous packaging and CI fixes courtesy of
+  `@Rotzbua <https://github.com/Rotzbua>`_ -- thanks for poking me on this project!
+
 v0.3.6
 ----------------------------------------------------------------------------------------
 
diff --git a/docs/requirements.txt b/docs/requirements.txt
index f712c7a..bffda5c 100644
--- a/docs/requirements.txt
+++ b/docs/requirements.txt
@@ -1,5 +1,5 @@
-sphinx==4.3.1
-sphinx_rtd_theme==1.0.0
+sphinx
+sphinx_rtd_theme
 sphinx-issues
 # exhale requirements
 beautifulsoup4
diff --git a/pyproject.toml b/pyproject.toml
index 98799e1..8fe2d75 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -18,10 +18,6 @@ filterwarnings = [
     "default::PendingDeprecationWarning",
     # Bypass docutils warning: DeprecationWarning: 'U' mode is deprecated
     "ignore::DeprecationWarning:docutils.io",
-    # Bypass breathe bug:
-    #   RemovedInSphinx30Warning: function based directive support is now deprecated.
-    #                             Use class based directive instead.
-    "ignore::PendingDeprecationWarning:sphinx.util.docutils",
 ]
 
 ########################################################################################
diff --git a/setup.cfg b/setup.cfg
index 200fac9..c3c21fd 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -23,24 +23,24 @@ classifiers =
     Natural Language :: English
     Programming Language :: Python
     Programming Language :: Python :: 3
-    Programming Language :: Python :: 3.7
     Programming Language :: Python :: 3.8
     Programming Language :: Python :: 3.9
     Programming Language :: Python :: 3.10
+    Programming Language :: Python :: 3.11
+    Programming Language :: Python :: 3.12
     Topic :: Documentation :: Sphinx
     Topic :: Software Development :: Documentation
 
 [options]
-python_requires = >=3.7
+python_requires = >=3.8
 zip_safe = False
 packages = find:
 # NOTE: making changes here?  Please also update tox.ini [testenv{deps}]!
 install_requires =
-    # From breathe==4.32.0
-    docutils>=0.12
-    Sphinx>=3.0,<7
-    # For exhale
-    breathe>=4.32.0
+    breathe>=4.33.1
+    # We're forcing a more modern sphinx to remove cruft from this repository,
+    # see the discussion: https://github.com/svenevs/exhale/issues/191
+    Sphinx>=4.3.2
     beautifulsoup4
     lxml
     # TODO: remove this dependency
diff --git a/tox.ini b/tox.ini
index f12ae29..8d86148 100644
--- a/tox.ini
+++ b/tox.ini
@@ -10,15 +10,12 @@ passenv =
 # usedevelop = true
 skip_install = true
 # NOTE: environment variables *MUST* include the `==`, e.g.,
-#       SPHINX_VERSION="==3.0.0" tox -e py
+#       SPHINX_VERSION="==X.Y.Z" tox -e py
 # This way, if the variable is not set, it uses the latest version.
 deps =
-    # TODO: drop this when sphinx 3.x is dropped.
-    # https://github.com/sphinx-doc/sphinx/issues/10291
-    Jinja2<3.1
     # requirements for exhale
-    sphinx{env:SPHINX_VERSION:}
-    breathe{env:BREATHE_VERSION:>=4.32.0}
+    sphinx{env:SPHINX_VERSION:>=4.3.2}
+    breathe{env:BREATHE_VERSION:>=4.33.1}
     beautifulsoup4
     # NOTE: for dev convenience, see https://github.com/svenevs/exhale/issues/131
     lxml>=4.6.4


Test patch:
diff --git a/.github/workflows/test_extras.yaml b/.github/workflows/test_extras.yaml
index e4a217e..51cfa33 100644
--- a/.github/workflows/test_extras.yaml
+++ b/.github/workflows/test_extras.yaml
@@ -62,10 +62,10 @@ jobs:
     steps:
       - uses: actions/checkout@v4
       # Use minimum version of python needed for this project in setup.cfg.
-      - name: Use Python 3.7
+      - name: Use Python 3.8
         uses: actions/setup-python@v4
         with:
-          python-version: '3.7'
+          python-version: '3.8'
       - name: Install Tools
         run: |
           pip install -U tox
diff --git a/.github/workflows/test_python.yaml b/.github/workflows/test_python.yaml
index 12432c8..d0f63a1 100644
--- a/.github/workflows/test_python.yaml
+++ b/.github/workflows/test_python.yaml
@@ -23,7 +23,7 @@ jobs:
       fail-fast: true
       matrix:
         os: [macos-latest, ubuntu-latest, windows-latest]
-        python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']
+        python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']
     steps:
       - uses: actions/checkout@v4
       ##################################################################################
@@ -37,21 +37,9 @@ jobs:
           sudo apt-get install -y doxygen
       - name: Install Doxygen (Windows)
         if: contains(matrix.os, 'windows')
-        run: |
-          # This command has been failing with source forge mirror issues
-          # choco install doxygen.install --version 1.9.6
-          #
-          # https://github.com/actions/runner-images/issues/92#issuecomment-1172456433
-          $url = "https://www.doxygen.nl/files/doxygen-1.9.6.windows.x64.bin.zip"
-          Start-DownloadWithRetry -Url $url -Name "doxygen.zip" -DownloadPath "C:\"
-          Extract-7Zip -Path  "C:\doxygen.zip" -DestinationPath "C:\Program Files\doxygen"
-          # Extracts to C:\Program Files\doxygen
-          #   - doxygen.exe
-          #   - doxyindexer.exe
-          #   - doxysearch.cgi.exe
-          #   - doxywizard.exe
-          #   - libclang.dll
-          echo "C:\Program Files\doxygen" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
+        uses: ssciwr/doxygen-install@v1
+          with:
+          version: "1.9.6"
       ##################################################################################
       - name: Doxygen Version Dump
         run: doxygen --version
@@ -62,34 +50,17 @@ jobs:
           python-version: ${{ matrix.python-version }}
       - name: Install Python Tools
         run: |
-          pip install -U pip tox codecov coverage
-      # Sphinx 3.0.0 ###################################################################
-      - name: Test Python ${{ matrix.python-version }} / sphinx==3.0.0
+          pip install tox codecov coverage
+      # Sphinx 4.3.2 ###################################################################
+      - name: Test Python ${{ matrix.python-version }} / sphinx==4.3.2
         env:
           # NOTE: this is the current minimum supported.
-          SPHINX_VERSION: '==3.0.0'
+          SPHINX_VERSION: '==4.3.2'
         run: |
           tox -e py -- --cov-report xml:coverage.xml --cov
-      - name: Upload Code Coverage for Python ${{ matrix.python-version }} / sphinx==3.0.0
+      - name: Upload Code Coverage for Python ${{ matrix.python-version }} / sphinx==4.3.2
         run: |
-          codecov --required -X gcov -f coverage.xml --name "[GHA] ${{ matrix.os }}-py${{ matrix.python-version }}-sphinx3.0.0"
-      # Don't let code coverage utilities share anything, force clean it all.
-      - name: Cleanup Python ${{ matrix.python-version }} Testing / Coverage Artifacts
-        run: |
-          mv .gitignore nolongerignored
-          git clean -n
-          git clean -f
-          git reset --hard
-      # Sphinx 4.x #####################################################################
-      - name: Test Python ${{ matrix.python-version }} / sphinx 4.x
-        env:
-          # Test sphinx 4.x.
-          SPHINX_VERSION: '>=4,<5'
-        run: |
-          tox -e py -- --cov-report xml:coverage.xml --cov
-      - name: Upload Code Coverage for Python ${{ matrix.python-version }} / sphinx 4.x
-        run: |
-          codecov --required -X gcov -f coverage.xml --name "[GHA] ${{ matrix.os }}-py${{ matrix.python-version }}-sphinx4.x"
+          codecov --required -X gcov -f coverage.xml --name "[GHA] ${{ matrix.os }}-py${{ matrix.python-version }}-sphinx4.3.2"
       # Don't let code coverage utilities share anything, force clean it all.
       - name: Cleanup Python ${{ matrix.python-version }} Testing / Coverage Artifacts
         run: |
@@ -116,14 +87,24 @@ jobs:
           git reset --hard
       # Sphinx 6.x #####################################################################
       - name: Test Python ${{ matrix.python-version }} / sphinx 6.x
-        # sphinx 6.x requires python 3.8+
-        if: ${{ matrix.python-version != '3.7' }}
         env:
           # Test sphinx 6.x.
           SPHINX_VERSION: '>=6,<7'
         run: |
           tox -e py -- --cov-report xml:coverage.xml --cov
       - name: Upload Code Coverage for Python ${{ matrix.python-version }} / sphinx 6.x
-        if: ${{ matrix.python-version != '3.7' }}
         run: |
           codecov --required -X gcov -f coverage.xml --name "[GHA] ${{ matrix.os }}-py${{ matrix.python-version }}-sphinx6.x"
+      # Sphinx 7.x #####################################################################
+      - name: Test Python ${{ matrix.python-version }} / sphinx 7.x
+        env:
+          # Test sphinx 7.x.
+          # TODO: breathe does not currently support later sphinx.
+          # https://github.com/svenevs/exhale/issues/203#issuecomment-1773060684
+          SPHINX_VERSION: '>=7,<7.2'
+        run: |
+          tox -e py -- --cov-report xml:coverage.xml --cov
+      - name: Upload Code Coverage for Python ${{ matrix.python-version }} / sphinx 7.x
+        run: |
+          codecov --required -X gcov -f coverage.xml --name "[GHA] ${{ matrix.os }}-py${{ matrix.python-version }}-sphinx7.x"
+