Fix(deps): Pin setuptools<82 to retain pkg_resources 07/143507/1 master
authorMatthew Watkins <mwatkins@linuxfoundation.org>
Thu, 5 Mar 2026 11:31:47 +0000 (11:31 +0000)
committerMatthew Watkins <mwatkins@linuxfoundation.org>
Thu, 5 Mar 2026 11:31:47 +0000 (11:31 +0000)
Setuptools v82.0.0 removed the bundled pkg_resources module.
This breaks RTD builds because sphinxcontrib-redoc imports
pkg_resources at the module level, causing:

  ModuleNotFoundError: No module named 'pkg_resources'

Pin setuptools>=65.0.0,<82 in docs requirements and tox.ini
to ensure pkg_resources remains available at build time.

The sphinxcontrib-redoc extension is unmaintained (last released
2020) but is actively used to generate OpenAPI/ReDoc pages for
all Policy component APIs. Replacing it requires a separate
migration effort.

Issue-ID: CIMAN-33
Co-Authored-By: Claude <noreply@anthropic.com>
Change-Id: I95c147913567caaf8f5070b61465c9db7cae64b5
Signed-off-by: Matthew Watkins <mwatkins@linuxfoundation.org>
docs/requirements-docs.txt
docs/tox.ini

index 9726e54..5c02f34 100644 (file)
@@ -1,3 +1,4 @@
+setuptools>=65.0.0,<82
 sphinx>=7.1.2
 sphinx-rtd-theme>=2.0.0
 sphinxcontrib-mermaid>=1.0.0
index c3c2aca..57d6741 100644 (file)
@@ -6,7 +6,7 @@ skipsdist = true
 [testenv:docs]
 basepython = python3.13
 deps =
-    setuptools>=65.0.0
+    setuptools>=65.0.0,<82
     -r{toxinidir}/requirements-docs.txt
     -chttps://git.onap.org/doc/plain/etc/upper-constraints.onap.txt?h=master
 commands =
@@ -19,7 +19,7 @@ allowlist_externals =
 [testenv:docs-linkcheck]
 basepython = python3.13
 deps =
-    setuptools>=65.0.0
+    setuptools>=65.0.0,<82
     -r{toxinidir}/requirements-docs.txt
     -chttps://git.onap.org/doc/plain/etc/upper-constraints.onap.txt?h=master
 commands =
@@ -28,7 +28,7 @@ commands =
 [testenv:docs-spellcheck]
 basepython = python3.13
 deps =
-    setuptools>=65.0.0
+    setuptools>=65.0.0,<82
     -r{toxinidir}/requirements-docs.txt
     -chttps://git.onap.org/doc/plain/etc/upper-constraints.onap.txt?h=master
 commands =