Sphinx 7.3.1__py3-none-any.whl → 7.3.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of Sphinx might be problematic. Click here for more details.

sphinx/__init__.py CHANGED
@@ -1,6 +1,6 @@
1
1
  """The Sphinx documentation toolchain."""
2
2
 
3
- __version__ = '7.3.1'
3
+ __version__ = '7.3.3'
4
4
  __display_version__ = __version__ # used for command line version
5
5
 
6
6
  # Keep this file executable as-is in Python 3!
@@ -28,7 +28,7 @@ warnings.filterwarnings(
28
28
  #:
29
29
  #: .. versionadded:: 1.2
30
30
  #: Before version 1.2, check the string ``sphinx.__version__``.
31
- version_info = (7, 3, 1, 'final', 0)
31
+ version_info = (7, 3, 3, 'final', 0)
32
32
 
33
33
  package_dir = path.abspath(path.dirname(__file__))
34
34
 
sphinx/config.py CHANGED
@@ -463,6 +463,9 @@ class Config:
463
463
  # create a picklable copy of ``self._options``
464
464
  __dict__['_options'] = _options = {}
465
465
  for name, opt in self._options.items():
466
+ if not isinstance(opt, _Opt) and isinstance(opt, tuple) and len(opt) <= 3:
467
+ # Fix for Furo's ``_update_default``.
468
+ self._options[name] = opt = _Opt(*opt)
466
469
  real_value = getattr(self, name)
467
470
  if not is_serializable(real_value):
468
471
  if opt.rebuild:
@@ -655,7 +658,7 @@ def check_confval_types(app: Sphinx | None, config: Config) -> None:
655
658
  if default is None and not valid_types:
656
659
  continue # neither inferable nor explicitly annotated types
657
660
 
658
- if valid_types is Any: # any type of value is accepted
661
+ if valid_types == frozenset({Any}): # any type of value is accepted
659
662
  continue
660
663
 
661
664
  if isinstance(valid_types, ENUM):
sphinx/theming.py CHANGED
@@ -159,6 +159,7 @@ class HTMLThemeFactory:
159
159
  self._load_builtin_themes()
160
160
  if getattr(app.config, 'html_theme_path', None):
161
161
  self._load_additional_themes(app.config.html_theme_path)
162
+ self._load_entry_point_themes()
162
163
 
163
164
  def _load_builtin_themes(self) -> None:
164
165
  """Load built-in themes."""
@@ -174,17 +175,14 @@ class HTMLThemeFactory:
174
175
  for name, theme in themes.items():
175
176
  self._themes[name] = theme
176
177
 
177
- def _load_extra_theme(self, name: str) -> None:
178
+ def _load_entry_point_themes(self) -> None:
178
179
  """Try to load a theme with the specified name.
179
180
 
180
181
  This uses the ``sphinx.html_themes`` entry point from package metadata.
181
182
  """
182
- theme_entry_points = entry_points(group='sphinx.html_themes')
183
- try:
184
- entry_point = theme_entry_points[name]
185
- except KeyError:
186
- pass
187
- else:
183
+ for entry_point in entry_points(group='sphinx.html_themes'):
184
+ if entry_point.name in self._themes:
185
+ continue # don't overwrite loaded themes
188
186
  self._app.registry.load_extension(self._app, entry_point.module)
189
187
  _config_post_init(self._app, self._app.config)
190
188
 
@@ -219,9 +217,6 @@ class HTMLThemeFactory:
219
217
 
220
218
  def create(self, name: str) -> Theme:
221
219
  """Create an instance of theme."""
222
- if name not in self._themes:
223
- self._load_extra_theme(name)
224
-
225
220
  if name not in self._themes:
226
221
  raise ThemeError(__('no theme named %r found (missing theme.toml?)') % name)
227
222
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: Sphinx
3
- Version: 7.3.1
3
+ Version: 7.3.3
4
4
  Summary: Python documentation generator
5
5
  Author-email: Georg Brandl <georg@python.org>
6
6
  Requires-Python: >=3.9
@@ -1,8 +1,8 @@
1
- sphinx/__init__.py,sha256=GPgFJjgncf13iYLEBXFU-uFjlsg3AS4BDP82h_snskg,1694
1
+ sphinx/__init__.py,sha256=9v3OcY9kF8sIR8cOQrfie2yItObd-9MShaiUgKdEiGM,1694
2
2
  sphinx/__main__.py,sha256=wIifwXlZHdi4gtQmkJ6KF0BsflvD9o0Wd5nARTdJc8A,127
3
3
  sphinx/addnodes.py,sha256=EQTIi9Zta6DaNa-2WGE3l9AVjdp7WzwwrfwRnax8vXE,18707
4
4
  sphinx/application.py,sha256=ICEmiMaOt4m0Wl2GBeHHulbZNcDvEpXMyfVuzDxcEhk,56266
5
- sphinx/config.py,sha256=JLzOGwR3OuUUsB5me3rZ7CxzT4iuPTtJJ5LTANUWGdU,29791
5
+ sphinx/config.py,sha256=8VjD3maDDxIHAjOmSHYPI3e92Wdy-BHNsirykNnWNLM,30000
6
6
  sphinx/deprecation.py,sha256=ABIo1t4mSwCTT2uxpUKNcwQHb3X6qur_tziCWzIhqtE,2437
7
7
  sphinx/errors.py,sha256=mFyE7P1fmnVTeYtpP3wv8oXrKyTw1H0WcE46VypUPd0,3412
8
8
  sphinx/events.py,sha256=3GE0v6gIu81Llbed-6zBPDy9G1a-tY9Z1ujUIGBBN5M,4351
@@ -16,7 +16,7 @@ sphinx/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
16
16
  sphinx/pygments_styles.py,sha256=0RJn6WC7rPnQu7BDqrqb0gkJcb3elRfizGVBW9bcmRE,2861
17
17
  sphinx/registry.py,sha256=LCWv2mDKNiN6IaE5tgUeWzmff9SFN7UWYwEN3QxbK4Q,22593
18
18
  sphinx/roles.py,sha256=8f9AJ8gUuOFrNzdgX6yhdE-Wc8ZeufoieMP4oL5lCAU,16964
19
- sphinx/theming.py,sha256=dfhbEdPJKWv1U5w9KIgyFr2CeqWTe0M1MTily5Eo0sE,18921
19
+ sphinx/theming.py,sha256=k71Gp6K9OrV-waG-dF3ZwtKJ9PnXCb-Do_teQUO_fvQ,18864
20
20
  sphinx/versioning.py,sha256=Kro82eLQvxD8RQShAipw_1GcwivuOrOO1SsDIigGWz0,5942
21
21
  sphinx/builders/__init__.py,sha256=E9Z1LeE_3lCq0vPs1Po2xliMkXF0awcRiK87C_9ZVgw,26851
22
22
  sphinx/builders/_epub_base.py,sha256=gtXo-PcmxLZs7t4VrETy5Ek1rOA5Uk35YNEyUtMvB24,29021
@@ -574,8 +574,8 @@ sphinx/writers/manpage.py,sha256=nLPgs3A5mVouhjiY2Olfoxh7PTFUZc1stHhThGDRSM4,161
574
574
  sphinx/writers/texinfo.py,sha256=YaVcaaK533HWd14FJkBJwkZZNL5Yh6rv2rcFrkhR4SU,53220
575
575
  sphinx/writers/text.py,sha256=HEiYXsWXO9QVOazg2V3D0ehGTnK38dAtYP9v0rst684,42964
576
576
  sphinx/writers/xml.py,sha256=NyDl82hCFSRiHrCZV6vBfn4AsAyXH6khtSJEfhOX8a0,1502
577
- sphinx-7.3.1.dist-info/entry_points.txt,sha256=KU_c9jqXj7yyZylSz11XRIXG3gAZApQa0d5DmcfyA7M,188
578
- sphinx-7.3.1.dist-info/LICENSE.rst,sha256=HdZPUFcmQaLySBc9fKvRC5aOUNkxL9Gz5py0p6XGDk4,3135
579
- sphinx-7.3.1.dist-info/WHEEL,sha256=EZbGkh7Ie4PoZfRQ8I0ZuP9VklN_TvcZ6DSE5Uar4z4,81
580
- sphinx-7.3.1.dist-info/METADATA,sha256=hHwNNTDdHbesW8tzldMlZeHcR9hBPP5XUi_ZUkzJF0g,6021
581
- sphinx-7.3.1.dist-info/RECORD,,
577
+ sphinx-7.3.3.dist-info/entry_points.txt,sha256=KU_c9jqXj7yyZylSz11XRIXG3gAZApQa0d5DmcfyA7M,188
578
+ sphinx-7.3.3.dist-info/LICENSE.rst,sha256=HdZPUFcmQaLySBc9fKvRC5aOUNkxL9Gz5py0p6XGDk4,3135
579
+ sphinx-7.3.3.dist-info/WHEEL,sha256=EZbGkh7Ie4PoZfRQ8I0ZuP9VklN_TvcZ6DSE5Uar4z4,81
580
+ sphinx-7.3.3.dist-info/METADATA,sha256=TD7CnP4K7q_LE1OvAEiZO_aHYBrVAMO-bqF9VcwODJM,6021
581
+ sphinx-7.3.3.dist-info/RECORD,,
File without changes