diff --git a/.gitignore b/.gitignore index 247a3ab..cc02dd5 100644 --- a/.gitignore +++ b/.gitignore @@ -36,3 +36,4 @@ /Sphinx-4.3.0.tar.gz /Sphinx-4.3.1.tar.gz /Sphinx-4.4.0.tar.gz +/Sphinx-4.5.0.tar.gz diff --git a/10336.patch b/10336.patch new file mode 100644 index 0000000..f79d764 --- /dev/null +++ b/10336.patch @@ -0,0 +1,23 @@ +From a314927e7451c255f7d4678feef32048dab5f9b2 Mon Sep 17 00:00:00 2001 +From: Adam Turner <9087854+aa-turner@users.noreply.github.com> +Date: Sat, 9 Apr 2022 20:38:47 +0100 +Subject: [PATCH] Fix test_restify + +--- + sphinx/util/typing.py | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/sphinx/util/typing.py b/sphinx/util/typing.py +index 1534b2c8ee..8e48b184bc 100644 +--- a/sphinx/util/typing.py ++++ b/sphinx/util/typing.py +@@ -215,6 +215,9 @@ def _restify_py37(cls: Optional[Type], mode: str = 'fully-qualified-except-typin + return text + elif isinstance(cls, typing._SpecialForm): + return ':py:obj:`~%s.%s`' % (cls.__module__, cls._name) ++ elif sys.version_info >= (3, 11) and cls is typing.Any: ++ # handle bpo-46998 ++ return f':py:obj:`~{cls.__module__}.{cls.__name__}`' + elif hasattr(cls, '__qualname__'): + if cls.__module__ == 'typing': + return ':py:class:`~%s.%s`' % (cls.__module__, cls.__qualname__) diff --git a/python-sphinx.spec b/python-sphinx.spec index ee84325..b8dbed1 100644 --- a/python-sphinx.spec +++ b/python-sphinx.spec @@ -24,7 +24,7 @@ %global upstream_name Sphinx Name: python-sphinx -%global general_version 4.4.0 +%global general_version 4.5.0 #global prerel ... %global upstream_version %{general_version}%{?prerel} Version: %{general_version}%{?prerel:~%{prerel}} @@ -45,6 +45,10 @@ Source0: %{pypi_source %{upstream_name} %{upstream_version}} # which causes that test to fail. Patch1: sphinx-test_theming.diff +# Fix test_restify for Python 3.11 +# https://github.com/sphinx-doc/sphinx/pull/10336 +Patch2: https://github.com/sphinx-doc/sphinx/pull/10336.patch + BuildArch: noarch BuildRequires: make @@ -364,6 +368,10 @@ mkdir %{buildroot}%{python3_sitelib}/sphinxcontrib %changelog +* Fri Apr 01 2022 Karolina Surma - 1:4.5.0-1 +- Update to 4.5.0 +- Fixes rhbz#2068924 + * Tue Feb 01 2022 Karolina Surma - 1:4.4.0-1 - Update to 4.4.0 - Fixes rhbz#2033955 diff --git a/sources b/sources index fa001e2..d5a34f0 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (Sphinx-4.4.0.tar.gz) = f5780a7da7a5d758b0e145ab9a7f191a9c65fd3ca4624ca3a04f0d161e3cd6c7133df53ff56e42f012687cbce0460178c2e7957974b5b929b341c98db996c640 +SHA512 (Sphinx-4.5.0.tar.gz) = b44d2a81ed67adaefe16a07ae0cf053b5e6c775023aaa6c57d7b3950f171deac410e8004f787b151c3c2fc350650aa69a4dc2dc7239d1fd3d351e5194617cb2c