Compare commits

...

23 Commits
f42 ... rawhide

Author SHA1 Message Date
Karolina Surma
3fa5c435e1 Update to 9.1.0 2026-02-11 14:49:28 +01:00
Karolina Surma
386cb6e874 Runtime dependencies are loaded by default now 2026-02-11 14:48:53 +01:00
Miro Hrončok
e4c31fd612 Debootsrap roman-numerals
[skip changelog]
2026-02-11 13:39:02 +01:00
Miro Hrončok
59303ae9d8 Use new package name for roman-numerals
- Fixes: rhbz#2438819

This is the bootstrap build that was necessary due to:

    Problem: package python3-sphinxcontrib-websupport-1.2.7-16.fc44.noarch requires python3.14dist(sphinx) >= 5, but none of the providers can be installed
      - package python3-sphinx-1:8.2.3-19.fc44.noarch requires python3.14dist(roman-numerals-py) >= 1, but none of the providers can be installed
      - package python3-roman-numerals-4.1.0-1.fc45.noarch obsoletes python3-roman-numerals-py < 4~~ provided by python3-roman-numerals-py-3.1.0-6.fc44.noarch
      - cannot install the best candidate for the job
      - conflicting requests
2026-02-11 13:16:15 +01:00
Miro Hrončok
4ac821f497 latex: Drop unnecessary requirement on obsoleted substitutefont
It is used *conditionally* in sphinx/texinputs/sphinxpackagesubstitutefont.sty.

See https://bugzilla.redhat.com/show_bug.cgi?id=2433763#c1 for details,
quoted here in case the reference gets lost in the future:

Tom "spot" Callaway from comment #1:

> python-sphinx [...] has a BuildRequires: tex(substitutefont.sty),
> but that component is no longer upstream.
> Sure enough, sphinx doesn't actually depend on the obsoleted
> substitutefont tex component (anymore) and has created a wrapper
> in sphinx/texinputs/sphinxpackagesubstitutefont.sty.
2026-01-29 13:53:44 +01:00
Fedora Release Engineering
b787bdf90d Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild 2026-01-17 09:51:03 +00:00
Karolina Surma
574c5a94d6 Ensure compatibility with python-docutils 0.22+ 2025-11-19 11:48:53 +01:00
Dennis van Raaij
d241286834 Make recommended TeX packages mandatory
Ensure that these packages are installed when building a package that
depends on python-sphinx-latex in a Koji build environment.
2025-10-20 21:18:27 +02:00
Dennis van Raaij
78fa545ec7 Don't build python-sphinx-latex for ELN
See also:
https://src.fedoraproject.org/rpms/python-sphinx/pull-request/74#comment-286281
2025-10-17 10:31:10 +02:00
Dennis van Raaij
0009cf4a25 Update the list of TeX packages required by Sphinx
Commands used to find the dependencies:

$ find ./sphinx -type f -and \( -name "*.sty" -or -name "*.tex*" \) \
    | xargs sed -n -e "s#.*\(RequirePackage.*\}\)#\1#p" \
    | sort | uniq

$ find ./sphinx -type f -and \( -name "*.sty" -or -name "*.tex*" \) \
    | xargs sed -n -e "s#.*\(IfFileExist.*\}\)#\1#p"\
    | sort | uniq

$ find ./sphinx -type f \
    | xargs sed -n -e "s#.*\(usepackage.*\}\).*#\1#p" \
    | sort | uniq
2025-10-14 23:11:35 +02:00
Dennis van Raaij
31b58a6666 Require package latexmk 2025-10-14 23:11:35 +02:00
Dennis van Raaij
bd77693107 Recommend package make 2025-10-14 23:11:25 +02:00
Python Maint
9db66313d0 Rebuilt for Python 3.14.0rc3 bytecode 2025-09-19 14:28:48 +02:00
Python Maint
9848821cbe Rebuilt for Python 3.14.0rc2 bytecode 2025-08-15 14:56:32 +02:00
Fedora Release Engineering
8d9f71877e Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild 2025-07-25 10:29:26 +00:00
Python Maint
5e29644eb4 Rebuilt for Python 3.14 2025-06-05 10:10:38 +02:00
Python Maint
0522916ddc Bootstrap for Python 3.14 2025-06-03 10:42:49 +02:00
Karolina Surma
aa73a643c5 Fix tests with Python 3.14.0a7+ 2025-05-30 15:39:34 +02:00
Yaakov Selkowitz
600e566ce8 Disable snowballstemmer dependency on RHEL
RHEL does not include snowball/libstemmer:

https://gitlab.com/redhat/centos-stream/rpms/python-sphinx/-/merge_requests/9
2025-05-09 13:34:41 -04:00
Yaakov Selkowitz
94392caedd Avoid pytest-xdist dependency on RHEL
python-pytest-xdist is not included in RHEL.
2025-04-10 01:24:22 -04:00
Miro Hrončok
bdccc31518 Drop test-dependency on defusedxml 2025-04-09 11:54:45 +00:00
Karolina Surma
1dedfd6334 Add compatibility with Python 3.14 2025-03-27 08:41:54 +01:00
Karolina Surma
de4dafa39e Update to 8.2.3 2025-03-06 11:06:50 +01:00
5 changed files with 200 additions and 62 deletions

2
.gitignore vendored
View File

@@ -48,3 +48,5 @@
/sphinx-7.2.6.tar.gz
/sphinx-7.3.7.tar.gz
/sphinx-8.1.3.tar.gz
/sphinx-8.2.3.tar.gz
/sphinx-9.1.0.tar.gz

View File

@@ -1,28 +1,28 @@
From 14adc6187c936738cb946c24c4a0820223d65066 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= <thrnciar@redhat.com>
Date: Wed, 13 Nov 2024 12:25:10 +0100
From 7b731f7ceb8161b11a529f182bf567b77993bdeb Mon Sep 17 00:00:00 2001
From: Karolina Surma <ksurma@redhat.com>
Date: Wed, 5 Mar 2025 12:14:49 +0100
Subject: [PATCH] Make the first party extensions optional, add [extensions]
extra
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Co-authored-by: Karolina Surma <ksurma@redhat.com>
Co-authored-by: Miro Hrončok <miro@hroncok.cz>
---
pyproject.toml | 33 ++++++++++++++++----
pyproject.toml | 35 ++++++++++++++++----
sphinx/application.py | 6 ++--
sphinx/registry.py | 9 ++++--
sphinx/testing/fixtures.py | 7 +++++
sphinx/registry.py | 10 +++---
sphinx/testing/fixtures.py | 7 ++++
tests/test_builders/test_build_html_maths.py | 3 ++
tests/test_writers/test_api_translator.py | 2 ++
6 files changed, 48 insertions(+), 12 deletions(-)
6 files changed, 50 insertions(+), 13 deletions(-)
diff --git a/pyproject.toml b/pyproject.toml
index 0812e11..3ead0e0 100644
index 1195b04..9a7213f 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -56,12 +56,6 @@ classifiers = [
"Topic :: Utilities",
@@ -67,12 +67,6 @@ classifiers = [
"Typing :: Typed",
]
dependencies = [
- "sphinxcontrib-applehelp>=1.0.7",
@@ -33,11 +33,12 @@ index 0812e11..3ead0e0 100644
- "sphinxcontrib-serializinghtml>=1.1.9",
"Jinja2>=3.1",
"Pygments>=2.17",
"docutils>=0.20,<0.22",
@@ -77,8 +71,35 @@ dependencies = [
"docutils>=0.21,<0.23",
@@ -87,6 +81,34 @@ dependencies = [
]
dynamic = ["version"]
[project.optional-dependencies]
+[project.optional-dependencies]
+applehelp = [
+ "sphinxcontrib-applehelp>=1.0.7",
+]
@@ -64,17 +65,23 @@ index 0812e11..3ead0e0 100644
+ "sphinx[serializinghtml]",
+ "sphinx[qthelp]",
+]
+
[[project.authors]]
name = "Adam Turner"
email = "aa-turner@users.noreply.github.com"
@@ -104,6 +126,7 @@ sphinx-autogen = "sphinx.ext.autosummary.generate:main"
[dependency-groups]
docs = [
"sphinxcontrib-websupport",
+ "sphinx[extensions]",
]
lint = [
"flake8>=6.0",
"ruff==0.14.9",
diff --git a/sphinx/application.py b/sphinx/application.py
index 872dd7a..21f9be0 100644
index 5349c36..4da1635 100644
--- a/sphinx/application.py
+++ b/sphinx/application.py
@@ -249,7 +249,7 @@ class Sphinx:
@@ -292,7 +292,7 @@ class Sphinx:
# load all built-in extension modules, first-party extension modules,
# and first-party themes
for extension in builtin_extensions:
@@ -83,7 +90,7 @@ index 872dd7a..21f9be0 100644
# load all user-given extension modules
for extension in self.config.extensions:
@@ -426,7 +426,7 @@ class Sphinx:
@@ -494,7 +494,7 @@ class Sphinx:
# ---- general extensibility interface -------------------------------------
@@ -92,7 +99,7 @@ index 872dd7a..21f9be0 100644
"""Import and setup a Sphinx extension module.
Load the extension given by the module *name*. Use this if your
@@ -434,7 +434,7 @@ class Sphinx:
@@ -502,7 +502,7 @@ class Sphinx:
called twice.
"""
logger.debug('[app] setting up extension: %r', extname)
@@ -102,19 +109,19 @@ index 872dd7a..21f9be0 100644
@staticmethod
def require_sphinx(version: tuple[int, int] | str) -> None:
diff --git a/sphinx/registry.py b/sphinx/registry.py
index da21aef..c3f87e0 100644
index da72924..b6f6122 100644
--- a/sphinx/registry.py
+++ b/sphinx/registry.py
@@ -436,7 +436,7 @@ class SphinxComponentRegistry:
def add_html_theme(self, name: str, theme_path: str) -> None:
self.html_themes[name] = theme_path
@@ -528,7 +528,7 @@ class SphinxComponentRegistry:
def add_html_theme(self, name: str, theme_path: str | os.PathLike[str]) -> None:
self.html_themes[name] = _StrPath(theme_path)
- def load_extension(self, app: Sphinx, extname: str) -> None:
+ def load_extension(self, app: Sphinx, extname: str, skip_nonimportable: bool = False) -> None:
"""Load a Sphinx extension."""
if extname in app.extensions: # already loaded
return
@@ -452,9 +452,12 @@ class SphinxComponentRegistry:
@@ -549,10 +549,12 @@ class SphinxComponentRegistry:
try:
mod = import_module(extname)
except ImportError as err:
@@ -123,14 +130,15 @@ index da21aef..c3f87e0 100644
+ logger.debug(msg % extname)
+ return
logger.verbose(__('Original exception:\n') + traceback.format_exc())
- raise ExtensionError(__('Could not import extension %s') % extname,
- err) from err
- raise ExtensionError(
- __('Could not import extension %s') % extname, err
- ) from err
+ raise ExtensionError(msg % extname, err) from err
setup: _ExtensionSetupFunc | None = getattr(mod, 'setup', None)
if setup is None:
diff --git a/sphinx/testing/fixtures.py b/sphinx/testing/fixtures.py
index 6f1c29c..425e026 100644
index c6fdebe..e9f98a8 100644
--- a/sphinx/testing/fixtures.py
+++ b/sphinx/testing/fixtures.py
@@ -31,6 +31,7 @@ DEFAULT_ENABLED_MARKERS = [
@@ -141,8 +149,8 @@ index 6f1c29c..425e026 100644
'test_params(shared_result=...): test parameters.',
]
@@ -80,6 +81,12 @@ def app_params(
Parameters that are specified by 'pytest.mark.sphinx' for
@@ -79,6 +80,12 @@ def app_params(
"""Parameters that are specified by 'pytest.mark.sphinx' for
sphinx.application.Sphinx initialization
"""
+
@@ -155,10 +163,10 @@ index 6f1c29c..425e026 100644
pargs: dict[int, Any] = {}
diff --git a/tests/test_builders/test_build_html_maths.py b/tests/test_builders/test_build_html_maths.py
index 0f77691..bc87e98 100644
index 8654ca9..8ad006f 100644
--- a/tests/test_builders/test_build_html_maths.py
+++ b/tests/test_builders/test_build_html_maths.py
@@ -26,6 +26,7 @@ def test_html_math_renderer_is_imgmath(app):
@@ -40,6 +40,7 @@ def test_html_math_renderer_is_imgmath(app: SphinxTestApp) -> None:
assert app.builder.math_renderer_name == 'imgmath'
@@ -166,7 +174,7 @@ index 0f77691..bc87e98 100644
@pytest.mark.sphinx(
'html',
testroot='basic',
@@ -50,6 +51,7 @@ def test_html_math_renderer_is_duplicated2(app):
@@ -67,6 +68,7 @@ def test_html_math_renderer_is_duplicated2(app: SphinxTestApp) -> None:
assert app.builder.math_renderer_name == 'imgmath' # The another one is chosen
@@ -174,7 +182,7 @@ index 0f77691..bc87e98 100644
@pytest.mark.sphinx(
'html',
testroot='basic',
@@ -62,6 +64,7 @@ def test_html_math_renderer_is_chosen(app):
@@ -80,6 +82,7 @@ def test_html_math_renderer_is_chosen(app: SphinxTestApp) -> None:
assert app.builder.math_renderer_name == 'imgmath'
@@ -183,25 +191,25 @@ index 0f77691..bc87e98 100644
'html',
testroot='basic',
diff --git a/tests/test_writers/test_api_translator.py b/tests/test_writers/test_api_translator.py
index bdbea0d..01d4d35 100644
index 1220192..8e8bb33 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):
@@ -47,6 +47,7 @@ def test_singlehtml_set_translator_for_singlehtml(app: SphinxTestApp) -> None:
assert translator_class.__name__ == 'ConfSingleHTMLTranslator'
+@pytest.mark.sphinxcontrib('serializinghtml')
@pytest.mark.sphinx('pickle', testroot='api-set-translator')
def test_pickle_set_translator_for_pickle(app):
def test_pickle_set_translator_for_pickle(app: SphinxTestApp) -> None:
translator_class = app.builder.get_translator_class()
@@ -43,6 +44,7 @@ def test_pickle_set_translator_for_pickle(app):
@@ -54,6 +55,7 @@ def test_pickle_set_translator_for_pickle(app: SphinxTestApp) -> None:
assert translator_class.__name__ == 'ConfPickleTranslator'
+@pytest.mark.sphinxcontrib('serializinghtml')
@pytest.mark.sphinx('json', testroot='api-set-translator')
def test_json_set_translator_for_json(app):
def test_json_set_translator_for_json(app: SphinxTestApp) -> None:
translator_class = app.builder.get_translator_class()
--
2.47.0
2.52.0

View File

@@ -2,6 +2,8 @@
# Without the packages, we have warnings in docs, but it's not a hard dependency
# We don't want to support sphinxcontrib-* in RHEL, hence disabling the dependencies
%bcond sphinxcontrib %{undefined rhel}
# RHEL does not include python3-snowballstemmer (SRPM: snowball)
%bcond snowballstemmer %{undefined rhel}
# Also, we don't have all the tests requirements
%bcond tests 1
@@ -16,10 +18,11 @@
%bcond imagemagick_tests %{undefined rhel}
# During texlive updates, sometimes the latex environment is unstable
# NOTE: LaTeX tests are never run when building for ELN.
%bcond latex_tests 1
Name: python-sphinx
%global general_version 8.1.3
%global general_version 9.1.0
#global prerel ...
%global upstream_version %{general_version}%{?prerel}
Version: %{general_version}%{?prerel:~%{prerel}}
@@ -82,36 +85,67 @@ BuildRequires: texinfo
BuildRequires: ImageMagick
%endif
%if %{with latex_tests}
%if %{undefined rhel} && %{with latex_tests}
BuildRequires: texlive-collection-fontsrecommended
BuildRequires: texlive-collection-latex
BuildRequires: texlive-gnu-freefont
BuildRequires: latexmk
BuildRequires: texlive-dvipng
BuildRequires: texlive-dvisvgm
BuildRequires: tex(article.cls)
BuildRequires: tex(utf8x.def)
# Other dependencies.
BuildRequires: tex(alltt.sty)
BuildRequires: tex(amsfonts.sty)
BuildRequires: tex(amsmath.sty)
BuildRequires: tex(amssymb.sty)
BuildRequires: tex(amstext.sty)
BuildRequires: tex(amsthm.sty)
BuildRequires: tex(anyfontsize.sty)
BuildRequires: tex(article.cls)
BuildRequires: tex(atbegshi.sty)
BuildRequires: tex(babel.sty)
BuildRequires: tex(bm.sty)
BuildRequires: tex(booktabs.sty)
BuildRequires: tex(capt-of.sty)
BuildRequires: tex(cmap.sty)
BuildRequires: tex(color.sty)
BuildRequires: tex(ctablestack.sty)
BuildRequires: tex(colortbl.sty)
BuildRequires: tex(ellipse.sty)
BuildRequires: tex(etoolbox.sty)
BuildRequires: tex(fancyhdr.sty)
BuildRequires: tex(fancyvrb.sty)
BuildRequires: tex(float.sty)
BuildRequires: tex(fncychap.sty)
BuildRequires: tex(fontawesome.sty)
BuildRequires: tex(fontawesome5.sty)
BuildRequires: tex(fontenc.sty)
BuildRequires: tex(fontspec.sty)
BuildRequires: tex(framed.sty)
BuildRequires: tex(FreeSerif.otf)
BuildRequires: tex(geometry.sty)
BuildRequires: tex(graphicx.sty)
BuildRequires: tex(hypcap.sty)
BuildRequires: tex(hyperref.sty)
BuildRequires: tex(inputenc.sty)
BuildRequires: tex(kvoptions.sty)
BuildRequires: tex(longtable.sty)
BuildRequires: tex(ltxcmds.sty)
BuildRequires: tex(luatex85.sty)
BuildRequires: tex(makeidx.sty)
BuildRequires: tex(multicol.sty)
BuildRequires: tex(needspace.sty)
BuildRequires: tex(parskip.sty)
BuildRequires: tex(pict2e.sty)
BuildRequires: tex(polyglossia.sty)
BuildRequires: tex(remreset.sty)
BuildRequires: tex(tabulary.sty)
BuildRequires: tex(textalpha.sty)
BuildRequires: tex(textcomp.sty)
BuildRequires: tex(tgheros.sty)
BuildRequires: tex(tgtermes.sty)
BuildRequires: tex(titlesec.sty)
BuildRequires: tex(upquote.sty)
BuildRequires: tex(utf8x.def)
BuildRequires: tex(varwidth.sty)
BuildRequires: tex(wrapfig.sty)
BuildRequires: tex(xcolor.sty)
%endif
%endif
@@ -150,6 +184,7 @@ Summary: Python documentation generator
Recommends: graphviz
Recommends: ImageMagick
Recommends: make
# Upstream Requires those, but we have a patch to remove the dependency.
# We keep them Recommended to preserve the default user experience.
@@ -190,39 +225,92 @@ the Python docs:
snippets and inclusion of appropriately formatted docstrings.
%if %{undefined rhel}
%package -n python%{python3_pkgversion}-sphinx-latex
Summary: LaTeX builder dependencies for python%{python3_pkgversion}-sphinx
Requires: python%{python3_pkgversion}-sphinx = %{epoch}:%{version}-%{release}
# Required dependencies as stated in the documentation [1]:
#
# - texlive-collection-latexrecommended
# - texlive-collection-fontsrecommended
# - texlive-collection-fontsextra
# - texlive-collection-latexextra
# - texlive-tex-gyre
# - latexmk
#
# [1] https://www.sphinx-doc.org/en/master/usage/builders/index.html#sphinx.builders.latex.LaTeXBuilder
#
# These packages install 2500+ other packages requiring ~3 GiB of space.
# Therefore, a more precise list of dependencies.
Requires: texlive-collection-fontsrecommended
Requires: texlive-collection-latex
Requires: texlive-gnu-freefont
Requires: latexmk
# Required by sphinx.ext.imgmath Render math as images
Requires: texlive-dvipng
Requires: texlive-dvisvgm
#Requires: tex(preview.sty) Pulls in texlive-collection-latexrecommended
Requires: tex(article.cls)
Requires: tex(utf8x.def)
# Other dependencies.
# -- After searching for \RequirePackage{..} and \usepackage{..}.
Requires: tex(alltt.sty)
Requires: tex(amsfonts.sty)
Requires: tex(amsmath.sty)
Requires: tex(amssymb.sty)
Requires: tex(amstext.sty)
Requires: tex(amsthm.sty)
Requires: tex(anyfontsize.sty)
Requires: tex(article.cls)
Requires: tex(atbegshi.sty)
Requires: tex(babel.sty)
Requires: tex(bm.sty)
Requires: tex(booktabs.sty)
Requires: tex(capt-of.sty)
Requires: tex(cmap.sty)
Requires: tex(color.sty)
Requires: tex(ctablestack.sty)
Requires: tex(colortbl.sty)
Requires: tex(ellipse.sty)
Requires: tex(etoolbox.sty)
Requires: tex(fancyhdr.sty)
Requires: tex(fancyvrb.sty)
Requires: tex(float.sty)
Requires: tex(fncychap.sty)
Requires: tex(fontawesome.sty)
Requires: tex(fontawesome5.sty)
Requires: tex(fontenc.sty)
Requires: tex(fontspec.sty)
Requires: tex(framed.sty)
Requires: tex(FreeSerif.otf)
Requires: tex(geometry.sty)
Requires: tex(graphicx.sty)
Requires: tex(hypcap.sty)
Requires: tex(hyperref.sty)
Requires: tex(inputenc.sty)
Requires: tex(kvoptions.sty)
Requires: tex(longtable.sty)
Requires: tex(ltxcmds.sty)
Requires: tex(luatex85.sty)
Requires: tex(makeidx.sty)
Requires: tex(multicol.sty)
Requires: tex(needspace.sty)
Requires: tex(parskip.sty)
Requires: tex(pict2e.sty)
Requires: tex(polyglossia.sty)
Requires: tex(remreset.sty)
Requires: tex(tabulary.sty)
Requires: tex(textalpha.sty)
Requires: tex(textcomp.sty)
Requires: tex(tgheros.sty)
Requires: tex(tgtermes.sty)
Requires: tex(titlesec.sty)
Requires: tex(upquote.sty)
Requires: tex(utf8x.def)
Requires: tex(varwidth.sty)
Requires: tex(wrapfig.sty)
Requires: tex(xcolor.sty)
#Requires: tex(xeCJK.sty) Pulls in pLaTeX and upLaTeX
# No files in this package, automatic provides don't work:
%py_provides python%{python3_pkgversion}-sphinx-latex
@@ -237,6 +325,7 @@ useful to many other projects.
This package pulls in the TeX dependencies needed by Sphinx's LaTeX
builder.
%endif
%package doc
@@ -258,13 +347,44 @@ This package contains documentation in the HTML format.
%prep
%autosetup -n sphinx-%{upstream_version} -p1
# Drop test-dependency on pytest-xdist
# This allows for parallel testing, but has a lot of dependencies.
# We want to avoid the dependency in RHEL, where it is not available.
%if 0%{?rhel}
sed -i -e '/pytest-xdist/d' pyproject.toml
%endif
# sphinx 9.1.0 requires pytest >= 9, which we don't have in Fedora yet
sed -i '/"pytest>=/ s/>=[^",]*//' pyproject.toml
# Drop test-dependency on defusedxml,
# use xml from the standard library instead.
# defusedxml is safer but this is only used in tests.
# Upstream uses defusedxml to be "safer for future contributors when they
# create/open branches and pull requests" -- that does not concern us.
# https://github.com/sphinx-doc/sphinx/pull/12168#discussion_r1535383868
# We want to avoid the dependency in RHEL, but no harm in doing so unconditionally.
sed -i '/"defusedxml/d' pyproject.toml
sed -i 's/from defusedxml./from xml.etree./' sphinx/testing/util.py tests/test_theming/test_theming.py
%if %{without snowballstemmer}
# Drop dependency on snowballstemmer for RHEL, implement dummy method instead
sed -i -e '/snowballstemmer/d' pyproject.toml
sed -i -e 's/^import \(snowballstemmer\)/from . import dummystemmer as \1/' sphinx/search/*.py
cat > sphinx/search/dummystemmer.py <<_EOF
class stemmer:
def __init__(self, *args, **kwargs): pass
def stemWord(self, word): return word
_EOF
%endif
%if %{without imagemagick_tests}
rm tests/test_extensions/test_ext_imgconverter.py
rm -r tests/test_ext_imgconverter/
%endif
%generate_buildrequires
%pyproject_buildrequires -r %{?with_tests:-x test}
%pyproject_buildrequires %{?with_tests:-g test}
%build
@@ -349,6 +469,14 @@ k="not test_autodoc_type_aliases"
k="${k} and not linkcheck and not test_latex_images and not test_build_latex_doc"
%endif
%if %{without snowballstemmer}
# Without snowballstemmer, some tests have to be skipped as well,
# as the results with dummystemmer do not exactly match the testcases
k="${k} and not test_meta_keys_are_handled_for_language_en and not test_stemmer"
k="${k} and not test_term_in_heading_and_section and not test_IndexBuilder"
k="${k} and not test_check_js_search_indexes"
%endif
%pytest -k "${k}"
%endif
@@ -364,10 +492,10 @@ k="${k} and not linkcheck and not test_latex_images and not test_build_latex_doc
%dir %{_datadir}/sphinx/locale/*
%{_mandir}/man1/sphinx-*
%if %{undefined rhel}
%files -n python%{python3_pkgversion}-sphinx-latex
# empty, this is a metapackage
%endif
%files doc
%license LICENSE.rst

View File

@@ -1 +1 @@
SHA512 (sphinx-8.1.3.tar.gz) = 938fc78941fd7b2bf3382730f2f9d322d406f87c80c0e4bf4c051a85a352c2c6241fe5b8d21574de7e4c1528090955eb84b6d23813b377b2be198a2cfa70221f
SHA512 (sphinx-9.1.0.tar.gz) = 2c8b16935e14a8f827110461c530275f431949159eef47380198115d8abadaafdca06680c09722c0df7fd8ed8e16dbe1e3aa62a774164b7987247f6d8f8a20d3

View File

@@ -1,6 +1,6 @@
From 57433d8036ab1e88ad7d6c4c1a45e438f722e276 Mon Sep 17 00:00:00 2001
From 399ae81dfbedb7b8acf84e56b0e4b2d5023432ec Mon Sep 17 00:00:00 2001
From: Karolina Surma <ksurma@redhat.com>
Date: Thu, 25 Apr 2024 16:07:56 +0200
Date: Wed, 26 Feb 2025 10:43:44 +0100
Subject: [PATCH] Patch test_theming to accomodate for Fedora-added theme
---
@@ -8,18 +8,18 @@ Subject: [PATCH] Patch test_theming to accomodate for Fedora-added theme
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/test_theming/test_theming.py b/tests/test_theming/test_theming.py
index 867f8a0..281bb45 100644
index 173e0c9..515e546 100644
--- a/tests/test_theming/test_theming.py
+++ b/tests/test_theming/test_theming.py
@@ -50,7 +50,7 @@ def test_theme_api(app, status, warning):
@@ -58,7 +58,7 @@ def test_theme_api(app: SphinxTestApp) -> None:
]
# test Theme class API
- assert set(app.registry.html_themes.keys()) == set(themes)
+ assert set(app.registry.html_themes.keys()) >= set(themes)
assert app.registry.html_themes['test-theme'] == str(
assert app.registry.html_themes['test-theme'] == (
app.srcdir / 'test_theme' / 'test-theme'
)
--
2.44.0
2.48.1