summaryrefslogtreecommitdiffstats
path: root/debian
diff options
context:
space:
mode:
Diffstat (limited to 'debian')
-rw-r--r--debian/changelog27
-rw-r--r--debian/control13
-rw-r--r--debian/copyright29
-rwxr-xr-xdebian/dh-sphinxdoc/dh_sphinxdoc2
-rw-r--r--debian/dh-sphinxdoc/index2
-rwxr-xr-xdebian/jstest/run-tests14
-rw-r--r--debian/patches/docutils_manpage_macros.diff12
-rw-r--r--debian/patches/intersphinx_local.diff8
-rw-r--r--debian/patches/move_sphinxcontrib_to_extras_require.diff10
-rw-r--r--debian/patches/python_3.11.7.diff77
-rw-r--r--debian/patches/python_3.12.3.diff25
-rw-r--r--debian/patches/remove_contrib_references.diff12
-rw-r--r--debian/patches/reproducible_searchindex.diff68
-rw-r--r--debian/patches/series5
-rw-r--r--debian/patches/skip_tests_jsmath.diff16
-rw-r--r--debian/patches/skip_tests_network.diff21
-rw-r--r--debian/patches/skip_tests_serializinghtml.diff10
-rw-r--r--debian/patches/support_old_search_indexes.diff48
-rw-r--r--debian/patches/use_packaged_mathjax.diff4
-rw-r--r--debian/python3-sphinx.preinst13
-rwxr-xr-xdebian/rules6
-rw-r--r--debian/sphinx-doc.docs2
-rw-r--r--debian/tests/control8
23 files changed, 115 insertions, 317 deletions
diff --git a/debian/changelog b/debian/changelog
index 292a422..dd44cf2 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,30 @@
+sphinx (7.3.7-1) experimental; urgency=medium
+
+ * New upstream release.
+ * Drop patches, included in the new release:
+ - python_3.11.7.diff
+ - python_3.12.3.diff
+ - reproducible_searchindex.diff
+ * Drop skip_tests_network.diff (closes: #1069774).
+ * Drop support_old_search_indexes.diff. Bookworm has Sphinx 5.3, so it
+ does not make sense to support older indexes anymore.
+ * Refresh other patches.
+ * Update path of ignored test file in debian/rules.
+ * Bump required python3-alabaster version to 0.7.14.
+ * Add dvisvgm to test dependencies and Suggests.
+ * Add cython3, gcc and python3-all-dev to test dependencies.
+ * Add python3-defusedxml to test dependencies.
+ * dh_sphinxdoc: Support loading searchindex.js with defer="defer".
+ * Install AUTHORS and CHANGES files with .rst extension.
+ * Remove debian/python3-sphinx.preinst, no longer needed.
+ * Update numbers in debian/jstest/run-tests.
+ * Update debian/copyright.
+ * dh_sphinxdoc: Bump minimum dependency version for searchtools.js.
+ * Update the command to replace links to docutils documentation.
+ * Bump Standards-Version to 4.7.0, no changes needed.
+
+ -- Dmitry Shachnev <mitya57@debian.org> Wed, 05 Jun 2024 16:35:21 +0300
+
sphinx (7.2.6-8~progress7.99u1) graograman-backports; urgency=medium
* Uploading to graograman-updates, remaining changes:
diff --git a/debian/control b/debian/control
index 9ae57d3..0d0da63 100644
--- a/debian/control
+++ b/debian/control
@@ -8,9 +8,11 @@ XSBC-Original-Uploaders: Dmitry Shachnev <mitya57@debian.org>
Bugs: mailto:maintainers@lists.progress-linux.org
Homepage: https://www.sphinx-doc.org/
Build-Depends: debhelper-compat (= 13)
-Build-Depends-Indep: dh-python (>= 3.20180313~),
+Build-Depends-Indep: cython3 <!nocheck>,
+ dh-python (>= 3.20180313~),
dpkg-dev (>= 1.17.14),
- dvipng,
+ dvipng <!nocheck>,
+ dvisvgm <!nocheck>,
flit (>= 3.7),
fonts-freefont-otf,
graphviz,
@@ -22,9 +24,11 @@ Build-Depends-Indep: dh-python (>= 3.20180313~),
perl,
pybuild-plugin-pyproject,
python-requests-doc <!nodoc>,
- python3-alabaster (>= 0.7),
+ python3-alabaster (>= 0.7.14),
python3-all (>= 3.3.3-1~),
+ python3-all-dev <!nocheck>,
python3-babel (>= 1.3),
+ python3-defusedxml <!nocheck>,
python3-doc <!nodoc>,
python3-docutils (>= 0.18.1),
python3-filelock <!nocheck>,
@@ -47,7 +51,7 @@ Build-Depends-Indep: dh-python (>= 3.20180313~),
texlive-luatex,
texlive-xetex
Rules-Requires-Root: no
-Standards-Version: 4.6.2
+Standards-Version: 4.7.0
Vcs-Browser: https://git.progress-linux.org/packages/graograman-backports/sphinx
Vcs-Git: https://git.progress-linux.org/packages/graograman-backports/sphinx
XSBC-Original-Vcs-Browser: https://salsa.debian.org/python-team/packages/sphinx
@@ -60,6 +64,7 @@ Depends: sphinx-common (= ${source:Version}),
${python3:Depends}
Recommends: make, python3-pil
Suggests: dvipng,
+ dvisvgm,
fonts-freefont-otf,
imagemagick-6.q16,
latexmk,
diff --git a/debian/copyright b/debian/copyright
index 80f793e..4acdf48 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -2,7 +2,7 @@ Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: Sphinx
Files: *
-Copyright: 2007-2023 the Sphinx team (see AUTHORS file)
+Copyright: 2007-2024 the Sphinx team (see AUTHORS file)
License: BSD-2-clause
Files: debian/dh-sphinxdoc/dh_sphinxdoc
@@ -13,13 +13,13 @@ License: BSD-2-clause
Files: sphinx/ext/apidoc.py
Copyright: 2008 Société des arts technologiques (SAT)
- 2007-2023 the Sphinx team
+ 2007-2024 the Sphinx team
License: BSD-2-clause
Files: sphinx/ext/napoleon/docstring.py
Copyright: 2008 Stefan van der Walt <stefan@mentat.za.net>
2008 Pauli Virtanen <pav@iki.fi>
- 2007-2023 the Sphinx team
+ 2007-2024 the Sphinx team
License: BSD-2-clause
Files: sphinx/search/minified-js/*
@@ -32,8 +32,8 @@ License: BSD-3-clause
Files: sphinx/themes/haiku/static/haiku.css_t
Copyright: 2008-2009 Haiku
- 2007-2023 the Sphinx team
-License: BSD-2-clause
+ 2007-2024 the Sphinx team
+License: Expat and BSD-2-clause
License: BSD-2-clause
Redistribution and use in source and binary forms, with or without
@@ -83,3 +83,22 @@ License: BSD-3-clause
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+License: Expat
+ Permission is hereby granted, free of charge, to any person obtaining a copy
+ of this software and associated documentation files (the "Software"), to deal
+ in the Software without restriction, including without limitation the rights
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ copies of the Software, and to permit persons to whom the Software is
+ furnished to do so, subject to the following conditions:
+ .
+ The above copyright notice and this permission notice shall be included in
+ all copies or substantial portions of the Software.
+ .
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ THE SOFTWARE.
diff --git a/debian/dh-sphinxdoc/dh_sphinxdoc b/debian/dh-sphinxdoc/dh_sphinxdoc
index ccd4a5a..fb74e9c 100755
--- a/debian/dh-sphinxdoc/dh_sphinxdoc
+++ b/debian/dh-sphinxdoc/dh_sphinxdoc
@@ -290,7 +290,7 @@ sub sanity_check($$)
}
}
defined $documentation_options or error("DOCUMENTATION_OPTIONS not found");
- my $loads_searchindex = $search =~ m{<script(?: type="text/javascript")? src="[^"]*searchindex.js\s?"(?: defer)?>};
+ my $loads_searchindex = $search =~ m{<script(?: type="text/javascript")? src="[^"]*searchindex.js\s?"(?: defer(?:="defer"))?>};
unless ($loads_searchindex)
{
# old style, used before Sphinx 2.0
diff --git a/debian/dh-sphinxdoc/index b/debian/dh-sphinxdoc/index
index 6217120..fe7384b 100644
--- a/debian/dh-sphinxdoc/index
+++ b/debian/dh-sphinxdoc/index
@@ -1,7 +1,7 @@
# <filename> [min-version]
1.0/doctools.js 5.2
1.0/language_data.js 2.4.3-5~
-1.0/searchtools.js 7.2.2
+1.0/searchtools.js 7.3
1.0/sidebar.js 5.0
1.0/theme_extras.js 5.0
1.0/css3-mediaqueries.js 1.3
diff --git a/debian/jstest/run-tests b/debian/jstest/run-tests
index 1285ccd..1310ebf 100755
--- a/debian/jstest/run-tests
+++ b/debian/jstest/run-tests
@@ -9,21 +9,21 @@ from PyQt6.QtWidgets import QApplication
class t1:
search_term = 'example'
- n_results = 85
- n_links = 85
- n_highlights = 101
+ n_results = 93
+ n_links = 93
+ n_highlights = 109
class t2:
search_term = 'examples'
- n_results = 76
- n_links = 76
- n_highlights = 17
+ n_results = 84
+ n_links = 84
+ n_highlights = 22
class t3:
search_term = 'graph'
n_results = 33
n_links = 33
- n_highlights = 124
+ n_highlights = 125
if __name__ == '__main__':
if not os.getenv('DISPLAY'):
diff --git a/debian/patches/docutils_manpage_macros.diff b/debian/patches/docutils_manpage_macros.diff
index 4bf22dc..b854af4 100644
--- a/debian/patches/docutils_manpage_macros.diff
+++ b/debian/patches/docutils_manpage_macros.diff
@@ -4,15 +4,15 @@ Subject: Make test_build_manpage pass with docutils 0.19+dfsg-7
I backported the change from upstream 0.21 to our 0.19 and 0.20 packaging.
---
- tests/test_build_manpage.py | 2 +-
+ tests/test_builders/test_build_manpage.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/tests/test_build_manpage.py b/tests/test_build_manpage.py
-index e765644..2fc2014 100644
---- a/tests/test_build_manpage.py
-+++ b/tests/test_build_manpage.py
+diff --git a/tests/test_builders/test_build_manpage.py b/tests/test_builders/test_build_manpage.py
+index 7172281..735f597 100644
+--- a/tests/test_builders/test_build_manpage.py
++++ b/tests/test_builders/test_build_manpage.py
@@ -52,7 +52,7 @@ def test_captioned_code_block(app, status, warning):
- app.builder.build_all()
+ app.build(force_all=True)
content = (app.outdir / 'python.1').read_text(encoding='utf8')
- if docutils.__version_info__[:2] < (0, 21):
diff --git a/debian/patches/intersphinx_local.diff b/debian/patches/intersphinx_local.diff
index 1eff330..8f63354 100644
--- a/debian/patches/intersphinx_local.diff
+++ b/debian/patches/intersphinx_local.diff
@@ -10,10 +10,10 @@ during build.
2 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/doc/conf.py b/doc/conf.py
-index 416158f..a262354 100644
+index 437b08f..8b21457 100644
--- a/doc/conf.py
+++ b/doc/conf.py
-@@ -117,9 +117,8 @@ texinfo_documents = [
+@@ -159,9 +159,8 @@ texinfo_documents = [
]
intersphinx_mapping = {
@@ -26,10 +26,10 @@ index 416158f..a262354 100644
# Sphinx document translation with sphinx gettext feature uses these settings:
diff --git a/doc/tutorial/deploying.rst b/doc/tutorial/deploying.rst
-index e16abdf..1c4e3c6 100644
+index 6b7913f..f5fd24e 100644
--- a/doc/tutorial/deploying.rst
+++ b/doc/tutorial/deploying.rst
-@@ -160,13 +160,16 @@ Read the Docs
+@@ -155,13 +155,16 @@ Read the Docs
~~~~~~~~~~~~~
`Read the Docs`_ offers integration with both GitHub and GitLab. The quickest
diff --git a/debian/patches/move_sphinxcontrib_to_extras_require.diff b/debian/patches/move_sphinxcontrib_to_extras_require.diff
index 9fa47ea..8e73096 100644
--- a/debian/patches/move_sphinxcontrib_to_extras_require.diff
+++ b/debian/patches/move_sphinxcontrib_to_extras_require.diff
@@ -7,10 +7,10 @@ Subject: Move sphinxcontrib modules to extras_require
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/pyproject.toml b/pyproject.toml
-index 0a9bc9e..6383e31 100644
+index 8aa49aa..5dbb696 100644
--- a/pyproject.toml
+++ b/pyproject.toml
-@@ -55,12 +55,6 @@ classifiers = [
+@@ -56,12 +56,6 @@ classifiers = [
"Topic :: Utilities",
]
dependencies = [
@@ -22,10 +22,10 @@ index 0a9bc9e..6383e31 100644
- "sphinxcontrib-qthelp",
"Jinja2>=3.0",
"Pygments>=2.14",
- "docutils>=0.18.1,<0.21",
-@@ -96,6 +90,14 @@ test = [
+ "docutils>=0.18.1,<0.22",
+@@ -98,6 +92,14 @@ test = [
+ "cython>=3.0",
"setuptools>=67.0", # for Cython compilation
- "filelock",
]
+sphinxcontrib = [
+ "sphinxcontrib-applehelp",
diff --git a/debian/patches/python_3.11.7.diff b/debian/patches/python_3.11.7.diff
deleted file mode 100644
index 02ed97f..0000000
--- a/debian/patches/python_3.11.7.diff
+++ /dev/null
@@ -1,77 +0,0 @@
-From: Hugo van Kemenade <hugovk@users.noreply.github.com>
-Date: Mon, 11 Dec 2023 12:01:55 +0200
-Subject: Fix autodoc tests for Python 3.11.7+
-
-Origin: https://github.com/sphinx-doc/sphinx/pull/11793
----
- tests/test_ext_autodoc_configs.py | 24 ++++++++++++++++++++----
- 1 file changed, 20 insertions(+), 4 deletions(-)
-
-diff --git a/tests/test_ext_autodoc_configs.py b/tests/test_ext_autodoc_configs.py
-index 45bc729..2e8f40c 100644
---- a/tests/test_ext_autodoc_configs.py
-+++ b/tests/test_ext_autodoc_configs.py
-@@ -1584,6 +1584,14 @@ def test_autodoc_typehints_format_fully_qualified_for_newtype_alias(app):
-
- @pytest.mark.sphinx('html', testroot='ext-autodoc')
- def test_autodoc_default_options(app):
-+ if (
-+ (3, 11, 7) <= sys.version_info < (3, 12)
-+ or sys.version_info >= (3, 12, 1)
-+ ):
-+ list_of_weak_references = " list of weak references to the object"
-+ else:
-+ list_of_weak_references = " list of weak references to the object (if defined)"
-+
- # no settings
- actual = do_autodoc(app, 'class', 'target.enums.EnumCls')
- assert ' .. py:attribute:: EnumCls.val1' not in actual
-@@ -1627,7 +1635,7 @@ def test_autodoc_default_options(app):
- assert ' Iterate squares of each value.' in actual
- if not IS_PYPY:
- assert ' .. py:attribute:: CustomIter.__weakref__' in actual
-- assert ' list of weak references to the object (if defined)' in actual
-+ assert list_of_weak_references in actual
-
- # :exclude-members: None - has no effect. Unlike :members:,
- # :special-members:, etc. where None == "include all", here None means
-@@ -1651,13 +1659,21 @@ def test_autodoc_default_options(app):
- assert ' Iterate squares of each value.' in actual
- if not IS_PYPY:
- assert ' .. py:attribute:: CustomIter.__weakref__' in actual
-- assert ' list of weak references to the object (if defined)' in actual
-+ assert list_of_weak_references in actual
- assert ' .. py:method:: CustomIter.snafucate()' in actual
- assert ' Makes this snafucated.' in actual
-
-
- @pytest.mark.sphinx('html', testroot='ext-autodoc')
- def test_autodoc_default_options_with_values(app):
-+ if (
-+ (3, 11, 7) <= sys.version_info < (3, 12)
-+ or sys.version_info >= (3, 12, 1)
-+ ):
-+ list_of_weak_references = " list of weak references to the object"
-+ else:
-+ list_of_weak_references = " list of weak references to the object (if defined)"
-+
- # with :members:
- app.config.autodoc_default_options = {'members': 'val1,val2'}
- actual = do_autodoc(app, 'class', 'target.enums.EnumCls')
-@@ -1698,7 +1714,7 @@ def test_autodoc_default_options_with_values(app):
- assert ' Iterate squares of each value.' in actual
- if not IS_PYPY:
- assert ' .. py:attribute:: CustomIter.__weakref__' not in actual
-- assert ' list of weak references to the object (if defined)' not in actual
-+ assert list_of_weak_references not in actual
-
- # with :exclude-members:
- app.config.autodoc_default_options = {
-@@ -1722,6 +1738,6 @@ def test_autodoc_default_options_with_values(app):
- assert ' Iterate squares of each value.' in actual
- if not IS_PYPY:
- assert ' .. py:attribute:: CustomIter.__weakref__' not in actual
-- assert ' list of weak references to the object (if defined)' not in actual
-+ assert list_of_weak_references not in actual
- assert ' .. py:method:: CustomIter.snafucate()' not in actual
- assert ' Makes this snafucated.' not in actual
diff --git a/debian/patches/python_3.12.3.diff b/debian/patches/python_3.12.3.diff
deleted file mode 100644
index 5df6857..0000000
--- a/debian/patches/python_3.12.3.diff
+++ /dev/null
@@ -1,25 +0,0 @@
-From: James Addison <55152140+jayaddison@users.noreply.github.com>
-Date: Fri, 8 Mar 2024 10:58:04 +0000
-Subject: [tests] reflect changes to Enum signature in Python 3.12.3 (#12054)
-
-(cherry picked from commit 5523c9bbe4d1415777669330411d4f00ad802f18)
----
- tests/test_ext_autodoc.py | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/tests/test_ext_autodoc.py b/tests/test_ext_autodoc.py
-index 7062763..5f63214 100644
---- a/tests/test_ext_autodoc.py
-+++ b/tests/test_ext_autodoc.py
-@@ -1407,7 +1407,10 @@ def test_enum_class(app):
- options = {"members": None}
- actual = do_autodoc(app, 'class', 'target.enums.EnumCls', options)
-
-- if sys.version_info[:2] >= (3, 12):
-+ if sys.version_info[:3] >= (3, 12, 3):
-+ args = ('(value, names=<not given>, *values, module=None, '
-+ 'qualname=None, type=None, start=1, boundary=None)')
-+ elif sys.version_info[:2] >= (3, 12):
- args = ('(value, names=None, *values, module=None, '
- 'qualname=None, type=None, start=1, boundary=None)')
- elif sys.version_info[:2] >= (3, 11):
diff --git a/debian/patches/remove_contrib_references.diff b/debian/patches/remove_contrib_references.diff
index 8510649..ce28b5b 100644
--- a/debian/patches/remove_contrib_references.diff
+++ b/debian/patches/remove_contrib_references.diff
@@ -10,10 +10,10 @@ dependency loops anyway.
2 files changed, 25 deletions(-)
diff --git a/doc/usage/builders/index.rst b/doc/usage/builders/index.rst
-index ce2c5dc..01172a7 100644
+index 9c538ee..21763c1 100644
--- a/doc/usage/builders/index.rst
+++ b/doc/usage/builders/index.rst
-@@ -68,12 +68,6 @@ The builder's "name" must be given to the **-b** command-line option of
+@@ -121,12 +121,6 @@ The most common builders are:
also generates HTML Help support files that allow the Microsoft HTML Help
Workshop to compile them into a CHM file.
@@ -26,7 +26,7 @@ index ce2c5dc..01172a7 100644
.. module:: sphinxcontrib.qthelp
.. class:: QtHelpBuilder
-@@ -85,12 +79,6 @@ The builder's "name" must be given to the **-b** command-line option of
+@@ -138,12 +132,6 @@ The most common builders are:
Moved to sphinxcontrib.qthelp from sphinx.builders package.
@@ -39,7 +39,7 @@ index ce2c5dc..01172a7 100644
.. _Qt help: https://doc.qt.io/qt-4.8/qthelp-framework.html
.. module:: sphinxcontrib.applehelp
-@@ -111,12 +99,6 @@ The builder's "name" must be given to the **-b** command-line option of
+@@ -164,12 +152,6 @@ The most common builders are:
output will not be valid until :program:`hiutil` has been run on all of the
``.lproj`` folders within the bundle.
@@ -52,7 +52,7 @@ index ce2c5dc..01172a7 100644
.. versionadded:: 1.3
.. versionchanged:: 2.0
-@@ -130,12 +112,6 @@ The builder's "name" must be given to the **-b** command-line option of
+@@ -183,12 +165,6 @@ The most common builders are:
also generates `GNOME Devhelp <https://wiki.gnome.org/Apps/Devhelp>`__
support file that allows the GNOME Devhelp reader to view them.
@@ -66,7 +66,7 @@ index ce2c5dc..01172a7 100644
Moved to sphinxcontrib.devhelp from sphinx.builders package.
diff --git a/sphinx/application.py b/sphinx/application.py
-index 73c157d..ebb47ca 100644
+index 7d16d9a..3791738 100644
--- a/sphinx/application.py
+++ b/sphinx/application.py
@@ -116,7 +116,6 @@ _first_party_themes = (
diff --git a/debian/patches/reproducible_searchindex.diff b/debian/patches/reproducible_searchindex.diff
deleted file mode 100644
index 13b32f9..0000000
--- a/debian/patches/reproducible_searchindex.diff
+++ /dev/null
@@ -1,68 +0,0 @@
-From: Pietro Albini <pietro@pietroalbini.org>
-Date: Sat, 16 Sep 2023 05:36:51 +0200
-Subject: Make `searchindex.js` deterministic (#11665)
-
-(cherry picked from commit 8e768e6c231c67caadecd5b43c20eb1f3a594079)
----
- sphinx/search/__init__.py | 2 +-
- tests/test_search.py | 37 +++++++++++++++++++++++++++++++++++++
- 2 files changed, 38 insertions(+), 1 deletion(-)
-
-diff --git a/sphinx/search/__init__.py b/sphinx/search/__init__.py
-index 21758d3..114d7fe 100644
---- a/sphinx/search/__init__.py
-+++ b/sphinx/search/__init__.py
-@@ -162,7 +162,7 @@ class _JavaScriptIndex:
- SUFFIX = ')'
-
- def dumps(self, data: Any) -> str:
-- return self.PREFIX + json.dumps(data) + self.SUFFIX
-+ return self.PREFIX + json.dumps(data, sort_keys=True) + self.SUFFIX
-
- def loads(self, s: str) -> Any:
- data = s[len(self.PREFIX):-len(self.SUFFIX)]
-diff --git a/tests/test_search.py b/tests/test_search.py
-index 68a7b01..d4bbef5 100644
---- a/tests/test_search.py
-+++ b/tests/test_search.py
-@@ -304,3 +304,40 @@ def test_parallel(app):
- app.build()
- index = load_searchindex(app.outdir / 'searchindex.js')
- assert index['docnames'] == ['index', 'nosearch', 'tocitem']
-+
-+
-+@pytest.mark.sphinx(testroot='search')
-+def test_search_index_is_deterministic(app):
-+ lists_not_to_sort = {
-+ # Each element of .titles is related to the element of .docnames in the same position.
-+ # The ordering is deterministic because .docnames is sorted.
-+ '.titles',
-+ # Each element of .filenames is related to the element of .docnames in the same position.
-+ # The ordering is deterministic because .docnames is sorted.
-+ '.filenames',
-+ }
-+
-+ # In the search index, titles inside .alltitles are stored as a tuple of
-+ # (document_idx, title_anchor). Tuples are represented as lists in JSON,
-+ # but their contents must not be sorted. We cannot sort them anyway, as
-+ # document_idx is an int and title_anchor is a str.
-+ def is_title_tuple_type(item):
-+ return len(item) == 2 and isinstance(item[0], int) and isinstance(item[1], str)
-+
-+ def assert_is_sorted(item, path):
-+ err_path = path if path else '<root>'
-+ if isinstance(item, dict):
-+ assert list(item.keys()) == sorted(item.keys()), f'{err_path} is not sorted'
-+ for key, value in item.items():
-+ assert_is_sorted(value, f'{path}.{key}')
-+ elif isinstance(item, list):
-+ if not is_title_tuple_type(item) and path not in lists_not_to_sort:
-+ assert item == sorted(item), f'{err_path} is not sorted'
-+ for i, child in enumerate(item):
-+ assert_is_sorted(child, f'{path}[{i}]')
-+
-+ app.builder.build_all()
-+ index = load_searchindex(app.outdir / 'searchindex.js')
-+ # Pretty print the index. Only shown by pytest on failure.
-+ print(f'searchindex.js contents:\n\n{json.dumps(index, indent=2)}')
-+ assert_is_sorted(index, '')
diff --git a/debian/patches/series b/debian/patches/series
index 3ec9d2b..f33bbe2 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,3 @@
-skip_tests_network.diff
no_external_css.diff
remove_contrib_references.diff
skip_tests_jsmath.diff
@@ -6,8 +5,4 @@ use_packaged_mathjax.diff
skip_tests_serializinghtml.diff
move_sphinxcontrib_to_extras_require.diff
intersphinx_local.diff
-support_old_search_indexes.diff
docutils_manpage_macros.diff
-python_3.11.7.diff
-python_3.12.3.diff
-reproducible_searchindex.diff
diff --git a/debian/patches/skip_tests_jsmath.diff b/debian/patches/skip_tests_jsmath.diff
index 32647a4..ad718e0 100644
--- a/debian/patches/skip_tests_jsmath.diff
+++ b/debian/patches/skip_tests_jsmath.diff
@@ -3,14 +3,14 @@ Date: Wed, 25 Dec 2019 23:37:50 +0300
Subject: Skip tests that require sphinxcontrib.jsmath module
---
- tests/test_build_html.py | 3 +++
+ tests/test_builders/test_build_html_maths.py | 3 +++
1 file changed, 3 insertions(+)
-diff --git a/tests/test_build_html.py b/tests/test_build_html.py
-index 07f101d..beef440 100644
---- a/tests/test_build_html.py
-+++ b/tests/test_build_html.py
-@@ -1544,6 +1544,7 @@ def test_html_math_renderer_is_imgmath(app, status, warning):
+diff --git a/tests/test_builders/test_build_html_maths.py b/tests/test_builders/test_build_html_maths.py
+index 900846b..3870093 100644
+--- a/tests/test_builders/test_build_html_maths.py
++++ b/tests/test_builders/test_build_html_maths.py
+@@ -20,6 +20,7 @@ def test_html_math_renderer_is_imgmath(app, status, warning):
assert app.builder.math_renderer_name == 'imgmath'
@@ -18,7 +18,7 @@ index 07f101d..beef440 100644
@pytest.mark.sphinx('html', testroot='basic',
confoverrides={'extensions': ['sphinxcontrib.jsmath',
'sphinx.ext.imgmath']})
-@@ -1564,6 +1565,7 @@ def test_html_math_renderer_is_duplicated2(app, status, warning):
+@@ -40,6 +41,7 @@ def test_html_math_renderer_is_duplicated2(app, status, warning):
assert app.builder.math_renderer_name == 'imgmath' # The another one is chosen
@@ -26,7 +26,7 @@ index 07f101d..beef440 100644
@pytest.mark.sphinx('html', testroot='basic',
confoverrides={'extensions': ['sphinxcontrib.jsmath',
'sphinx.ext.imgmath'],
-@@ -1572,6 +1574,7 @@ def test_html_math_renderer_is_chosen(app, status, warning):
+@@ -48,6 +50,7 @@ def test_html_math_renderer_is_chosen(app, status, warning):
assert app.builder.math_renderer_name == 'imgmath'
diff --git a/debian/patches/skip_tests_network.diff b/debian/patches/skip_tests_network.diff
deleted file mode 100644
index 60fe57c..0000000
--- a/debian/patches/skip_tests_network.diff
+++ /dev/null
@@ -1,21 +0,0 @@
-From: Dmitry Shachnev <mitya57@debian.org>
-Date: Tue, 20 Dec 2016 16:37:32 +0300
-Subject: Skip tests that require network access
-
-Forwarded: not-needed
----
- tests/test_build_latex.py | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/tests/test_build_latex.py b/tests/test_build_latex.py
-index f6c3369..5996203 100644
---- a/tests/test_build_latex.py
-+++ b/tests/test_build_latex.py
-@@ -1420,6 +1420,7 @@ def test_latex_raw_directive(app, status, warning):
- assert 'LaTeX: abc def ghi' in result
-
-
-+@pytest.mark.skip('Requires internet access')
- @pytest.mark.sphinx('latex', testroot='images')
- def test_latex_images(app, status, warning):
- app.builder.build_all()
diff --git a/debian/patches/skip_tests_serializinghtml.diff b/debian/patches/skip_tests_serializinghtml.diff
index b9401cc..22198db 100644
--- a/debian/patches/skip_tests_serializinghtml.diff
+++ b/debian/patches/skip_tests_serializinghtml.diff
@@ -3,13 +3,13 @@ Date: Thu, 6 Feb 2020 23:55:28 +0300
Subject: Skip tests that require sphinxcontrib.serializinghtml module
---
- tests/test_api_translator.py | 2 ++
+ tests/test_writers/test_api_translator.py | 2 ++
1 file changed, 2 insertions(+)
-diff --git a/tests/test_api_translator.py b/tests/test_api_translator.py
-index 2185fb8..66aa17f 100644
---- a/tests/test_api_translator.py
-+++ b/tests/test_api_translator.py
+diff --git a/tests/test_writers/test_api_translator.py b/tests/test_writers/test_api_translator.py
+index 9f2bd44..1c8defb 100644
+--- a/tests/test_writers/test_api_translator.py
++++ b/tests/test_writers/test_api_translator.py
@@ -36,6 +36,7 @@ def test_singlehtml_set_translator_for_singlehtml(app, status, warning):
assert translator_class.__name__ == 'ConfSingleHTMLTranslator'
diff --git a/debian/patches/support_old_search_indexes.diff b/debian/patches/support_old_search_indexes.diff
deleted file mode 100644
index 450e5e8..0000000
--- a/debian/patches/support_old_search_indexes.diff
+++ /dev/null
@@ -1,48 +0,0 @@
-From: Dmitry Shachnev <mitya57@debian.org>
-Date: Sat, 11 Dec 2021 19:19:27 +0300
-Subject: Make searchtools.js support documentation built with old Sphinx
-
-Sphinx 4.3 has changed format of searchindex.js files, but in Debian
-there are lots of packages built with older Sphinx, and we want to
-keep them working for some time.
-
-Also support legacy custom search.html templates, which don't have
-data-content_root attribute on the top-level element.
-
-Forwarded: not-needed
----
- sphinx/themes/basic/static/searchtools.js | 12 ++++++++----
- 1 file changed, 8 insertions(+), 4 deletions(-)
-
-diff --git a/sphinx/themes/basic/static/searchtools.js b/sphinx/themes/basic/static/searchtools.js
-index 7918c3f..09d6458 100644
---- a/sphinx/themes/basic/static/searchtools.js
-+++ b/sphinx/themes/basic/static/searchtools.js
-@@ -62,7 +62,8 @@ const _displayItem = (item, searchTerms, highlightTerms) => {
- const docFileSuffix = DOCUMENTATION_OPTIONS.FILE_SUFFIX;
- const docLinkSuffix = DOCUMENTATION_OPTIONS.LINK_SUFFIX;
- const showSearchSummary = DOCUMENTATION_OPTIONS.SHOW_SEARCH_SUMMARY;
-- const contentRoot = document.documentElement.dataset.content_root;
-+ const contentRoot = document.documentElement.dataset.content_root
-+ ?? DOCUMENTATION_OPTIONS.URL_ROOT;
-
- const [docName, title, anchor, descr, score, _filename] = item;
-
-@@ -434,11 +435,14 @@ const Search = {
- filenames[match[0]],
- ]);
- };
-- Object.keys(objects).forEach((prefix) =>
-+ Object.keys(objects).forEach((prefix) => {
-+ if (!(objects[prefix] instanceof Array)) {
-+ objects[prefix] = Object.entries(objects[prefix]).map(([name, match]) => [...match, name]);
-+ }
- objects[prefix].forEach((array) =>
- objectSearchCallback(prefix, array)
-- )
-- );
-+ );
-+ });
- return results;
- },
-
diff --git a/debian/patches/use_packaged_mathjax.diff b/debian/patches/use_packaged_mathjax.diff
index 28405ca..e9694da 100644
--- a/debian/patches/use_packaged_mathjax.diff
+++ b/debian/patches/use_packaged_mathjax.diff
@@ -7,10 +7,10 @@ Subject: Use packaged MathJax (for our own documentation)
1 file changed, 1 insertion(+)
diff --git a/doc/conf.py b/doc/conf.py
-index d4915aa..416158f 100644
+index 49fcba4..437b08f 100644
--- a/doc/conf.py
+++ b/doc/conf.py
-@@ -185,6 +185,7 @@ nitpick_ignore = {
+@@ -230,6 +230,7 @@ nitpick_ignore = {
('std:confval', 'globaltoc_maxdepth'),
}
diff --git a/debian/python3-sphinx.preinst b/debian/python3-sphinx.preinst
deleted file mode 100644
index b4b7bd6..0000000
--- a/debian/python3-sphinx.preinst
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-set -e
-
-if [ "$1" = upgrade ] && dpkg --compare-versions "$2" lt 2.4.3-3~
-then
- for exe in /usr/share/sphinx/scripts/python3/*
- do
- update-alternatives --remove ${exe##*/} $exe
- done
-fi
-
-#DEBHELPER#
diff --git a/debian/rules b/debian/rules
index 0a40e5d..237612d 100755
--- a/debian/rules
+++ b/debian/rules
@@ -5,7 +5,7 @@ export NO_PKG_MANGLE=1
export LC_ALL=C.UTF-8
export PYTHONWARNINGS=d
-export PYBUILD_TEST_ARGS=--verbose --ignore tests/test_api_translator.py
+export PYBUILD_TEST_ARGS=--verbose --ignore tests/test_writers/test_api_translator.py
locales = $(notdir $(patsubst %/LC_MESSAGES,%,$(wildcard sphinx/locale/*/LC_MESSAGES)))
@@ -22,7 +22,7 @@ override_dh_auto_build:
ifeq "$(filter nodoc,$(DEB_BUILD_OPTIONS))" ""
PYTHONPATH=$(py3_builddir) python3 ./sphinx/cmd/build.py -T doc build/html/
find build/html/ -name '*.txt' -or -name '*.html' | xargs -L1 sed -i \
- 's!http://docutils.sourceforge.net/docs/!file:///usr/share/doc/docutils-doc/docs/!g'
+ 's!https://docutils.sourceforge.io/docs/!file:///usr/share/doc/docutils-doc/docs/!g'
PYTHONPATH=$(py3_builddir) python3 ./sphinx/cmd/build.py -T -b man doc build/man
endif
PYTHONPATH=$(py3_builddir) python3 ./utils/babel_runner.py compile
@@ -64,7 +64,7 @@ override_dh_auto_install:
done
override_dh_installchangelogs:
- dh_installchangelogs CHANGES
+ dh_installchangelogs CHANGES.rst
override_dh_installdocs:
dh_installdocs
diff --git a/debian/sphinx-doc.docs b/debian/sphinx-doc.docs
index 79c4f46..f815fbb 100644
--- a/debian/sphinx-doc.docs
+++ b/debian/sphinx-doc.docs
@@ -1,3 +1,3 @@
-AUTHORS
+AUTHORS.rst
README.rst
build/html
diff --git a/debian/tests/control b/debian/tests/control
index 3e6c688..c05188a 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -1,10 +1,14 @@
Tests: python3-sphinx
-Depends: dvipng,
+Depends: cython3,
+ dvipng,
+ dvisvgm,
fonts-freefont-otf,
+ gcc,
graphviz,
imagemagick-6.q16,
librsvg2-bin,
- python3-all,
+ python3-all-dev,
+ python3-defusedxml,
python3-filelock,
python3-html5lib,
python3-pytest,