summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--debian/changelog13
-rw-r--r--debian/control3
-rw-r--r--debian/patches/python_3.12.4.diff33
-rw-r--r--debian/patches/series1
-rw-r--r--debian/tests/control4
5 files changed, 49 insertions, 5 deletions
diff --git a/debian/changelog b/debian/changelog
index 4d5a8c4..9bc8c88 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,16 @@
+sphinx (7.3.7-2) experimental; urgency=medium
+
+ * Make python3-sphinx depend on python3-defusedxml, needed by
+ sphinx.testing.util module.
+ * Remove no longer needed test dependencies (thanks Piotr Ożarowski):
+ - python3-sphinxcontrib.websupport
+ - python3-sqlalchemy
+ - python3-whoosh
+ - python3-xapian
+ * Backport upstream patch to fix tests with Python 3.12.4.
+
+ -- Dmitry Shachnev <mitya57@debian.org> Thu, 13 Jun 2024 20:51:07 +0300
+
sphinx (7.3.7-1~progress7.99u1) graograman-backports; urgency=medium
* Uploading to graograman-backports, remaining changes:
diff --git a/debian/control b/debian/control
index 0d0da63..d0affcb 100644
--- a/debian/control
+++ b/debian/control
@@ -59,7 +59,8 @@ XSBC-Original-Vcs-Git: https://salsa.debian.org/python-team/packages/sphinx.git
Package: python3-sphinx
Architecture: all
-Depends: sphinx-common (= ${source:Version}),
+Depends: python3-defusedxml (>= 0.7.1),
+ sphinx-common (= ${source:Version}),
${misc:Depends},
${python3:Depends}
Recommends: make, python3-pil
diff --git a/debian/patches/python_3.12.4.diff b/debian/patches/python_3.12.4.diff
new file mode 100644
index 0000000..9e7d09a
--- /dev/null
+++ b/debian/patches/python_3.12.4.diff
@@ -0,0 +1,33 @@
+From: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
+Date: Tue, 23 Apr 2024 20:25:34 +0200
+Subject: Fix `sphinx.util.inspect_evaluate_forwardref` for Python 3.12.4
+ (#12317)
+
+Python has recently [1] changed the signature of `_evaluate` for forward references
+because of type parameters. The change affects 3.13, and was backported to 3.12.4.
+
+[1]: https://github.com/python/cpython/pull/118104
+
+(cherry picked from commit b5f3ef987ab5c2147d651ad84cc7d72c84ac6acc)
+---
+ sphinx/util/inspect.py | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/sphinx/util/inspect.py b/sphinx/util/inspect.py
+index 6b13b29..dfb4e40 100644
+--- a/sphinx/util/inspect.py
++++ b/sphinx/util/inspect.py
+@@ -681,6 +681,13 @@ def _evaluate_forwardref(
+ localns: dict[str, Any] | None,
+ ) -> Any:
+ """Evaluate a forward reference."""
++ if sys.version_info >= (3, 12, 4):
++ # ``type_params`` were added in 3.13 and the signature of _evaluate()
++ # is not backward-compatible (it was backported to 3.12.4, so anything
++ # before 3.12.4 still has the old signature).
++ #
++ # See: https://github.com/python/cpython/pull/118104.
++ return ref._evaluate(globalns, localns, {}, recursive_guard=frozenset()) # type: ignore[arg-type, misc]
+ return ref._evaluate(globalns, localns, frozenset())
+
+
diff --git a/debian/patches/series b/debian/patches/series
index f33bbe2..951abc3 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -6,3 +6,4 @@ skip_tests_serializinghtml.diff
move_sphinxcontrib_to_extras_require.diff
intersphinx_local.diff
docutils_manpage_macros.diff
+python_3.12.4.diff
diff --git a/debian/tests/control b/debian/tests/control
index c05188a..1a501fb 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -14,10 +14,6 @@ Depends: cython3,
python3-pytest,
python3-setuptools,
python3-sphinx,
- python3-sphinxcontrib.websupport,
- python3-sqlalchemy (>= 0.9),
- python3-whoosh,
- python3-xapian,
tex-gyre,
texinfo,
texlive-fonts-recommended,