Skip to content

Commit 187f6e6

Browse files
committed
fix doc build
1 parent a022829 commit 187f6e6

File tree

2 files changed

+47
-35
lines changed

2 files changed

+47
-35
lines changed

doc/source/conf.py

Lines changed: 45 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# All configuration values have a default; values that are commented out
1313
# serve to show the default.
1414

15-
import pkg_resources
15+
import importlib.metadata
1616

1717
# If extensions (or modules to document with autodoc) are in another directory,
1818
# add these directories to sys.path here. If the directory is relative to the
@@ -28,57 +28,57 @@
2828
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
2929
# ones.
3030
extensions = [
31-
'sphinx.ext.intersphinx',
32-
'sphinx.ext.autodoc',
33-
'sphinxcontrib.datatemplates',
31+
"sphinx.ext.intersphinx",
32+
"sphinx.ext.autodoc",
33+
"sphinxcontrib.datatemplates",
3434
"sphinxcontrib.runcmd",
3535
]
3636

3737
# Support linking to Python Docs
3838
intersphinx_mapping = {
39-
'python': ('https://docs.python.org/', None),
40-
'python3': ('https://docs.python.org/3', None),
41-
'python2': ('https://docs.python.org/2', None)
39+
"python": ("https://docs.python.org/", None),
40+
"python3": ("https://docs.python.org/3", None),
41+
"python2": ("https://docs.python.org/2", None),
4242
}
4343

4444
# Add any paths that contain templates here, relative to this directory.
45-
templates_path = ['_templates']
45+
templates_path = ["_templates"]
4646

4747
# The suffix(es) of source filenames.
4848
# You can specify multiple suffix as a list of string:
4949
# source_suffix = ['.rst', '.md']
50-
source_suffix = '.rst'
50+
source_suffix = ".rst"
5151

5252
# The encoding of source files.
5353
# source_encoding = 'utf-8-sig'
5454

5555
# The master toctree document.
56-
master_doc = 'index'
56+
master_doc = "index"
5757

5858
# General information about the project.
59-
project = u'sphinxcontrib.datatemplates'
60-
copyright = u'2015, Doug Hellmann'
61-
author = u'Doug Hellmann'
59+
project = "sphinxcontrib.datatemplates"
60+
copyright = "2015, Doug Hellmann"
61+
author = "Doug Hellmann"
6262

6363
# The version info for the project you're documenting, acts as replacement for
6464
# |version| and |release|, also used in various other places throughout the
6565
# built documents.
6666
#
6767
# The short X.Y version.
68-
version = pkg_resources.get_distribution('sphinxcontrib.datatemplates').version
68+
version = importlib.metadata.version("sphinxcontrib.datatemplates")
6969
# The full version, including alpha/beta/rc tags.
70-
release = '0.0.0'
70+
release = "0.0.0"
7171

7272
html_context = {
73-
'sample': 'Sample context value set in conf.py',
73+
"sample": "Sample context value set in conf.py",
7474
}
7575

7676
# The language for content autogenerated by Sphinx. Refer to documentation
7777
# for a list of supported languages.
7878
#
7979
# This is also used if you do content translation via gettext catalogs.
8080
# Usually you set "language" from the command line for these cases.
81-
language = 'en'
81+
language = "en"
8282

8383
# There are two options for replacing |today|: either, you set today to some
8484
# non-false value, then it is used:
@@ -106,7 +106,7 @@
106106
# show_authors = False
107107

108108
# The name of the Pygments (syntax highlighting) style to use.
109-
pygments_style = 'sphinx'
109+
pygments_style = "sphinx"
110110

111111
# A list of ignored prefixes for module index sorting.
112112
# modindex_common_prefix = []
@@ -150,7 +150,7 @@
150150
# Add any paths that contain custom static files (such as style sheets) here,
151151
# relative to this directory. They are copied after the builtin static files,
152152
# so a file named "default.css" will overwrite the builtin "default.css".
153-
html_static_path = ['_static']
153+
html_static_path = ["_static"]
154154

155155
# Add any extra paths that contain custom files (such as robots.txt or
156156
# .htaccess) here, relative to this directory. These files are copied
@@ -213,20 +213,17 @@
213213
# html_search_scorer = 'scorer.js'
214214

215215
# Output file base name for HTML help builder.
216-
htmlhelp_basename = 'sphinxcontribdatatemplatesdoc'
216+
htmlhelp_basename = "sphinxcontribdatatemplatesdoc"
217217

218218
# -- Options for LaTeX output ---------------------------------------------
219219

220220
latex_elements = {
221221
# The paper size ('letterpaper' or 'a4paper').
222222
# 'papersize': 'letterpaper',
223-
224223
# The font size ('10pt', '11pt' or '12pt').
225224
# 'pointsize': '10pt',
226-
227225
# Additional stuff for the LaTeX preamble.
228226
# 'preamble': '',
229-
230227
# Latex figure (float) alignment
231228
# 'figure_align': 'htbp',
232229
}
@@ -235,8 +232,13 @@
235232
# (source start file, target name, title,
236233
# author, documentclass [howto, manual, or own class]).
237234
latex_documents = [
238-
(master_doc, 'sphinxcontribdatatemplates.tex',
239-
u'sphinxcontrib.datatemplates Documentation', u'Doug Hellmann', 'manual'),
235+
(
236+
master_doc,
237+
"sphinxcontribdatatemplates.tex",
238+
"sphinxcontrib.datatemplates Documentation",
239+
"Doug Hellmann",
240+
"manual",
241+
),
240242
]
241243

242244
# The name of an image file (relative to this directory) to place at the top of
@@ -263,8 +265,15 @@
263265

264266
# One entry per manual page. List of tuples
265267
# (source start file, name, description, authors, manual section).
266-
man_pages = [(master_doc, 'sphinxcontribdatatemplates',
267-
u'sphinxcontrib.datatemplates Documentation', [author], 1)]
268+
man_pages = [
269+
(
270+
master_doc,
271+
"sphinxcontribdatatemplates",
272+
"sphinxcontrib.datatemplates Documentation",
273+
[author],
274+
1,
275+
)
276+
]
268277

269278
# If true, show URL addresses after external links.
270279
# man_show_urls = False
@@ -275,10 +284,15 @@
275284
# (source start file, target name, title, author,
276285
# dir menu entry, description, category)
277286
texinfo_documents = [
278-
(master_doc, 'sphinxcontribdatatemplates',
279-
u'sphinxcontrib.datatemplates Documentation', author,
280-
'sphinxcontribdatatemplates', 'One line description of project.',
281-
'Miscellaneous'),
287+
(
288+
master_doc,
289+
"sphinxcontribdatatemplates",
290+
"sphinxcontrib.datatemplates Documentation",
291+
author,
292+
"sphinxcontribdatatemplates",
293+
"One line description of project.",
294+
"Miscellaneous",
295+
),
282296
]
283297

284298
# Documents to append as an appendix to all manuals.

pyproject.toml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,14 @@ classifiers = [
1818
"License :: OSI Approved :: BSD License",
1919
"Operating System :: OS Independent",
2020
"Programming Language :: Python",
21-
"Programming Language :: Python :: 3.8",
22-
"Programming Language :: Python :: 3.9",
23-
"Programming Language :: Python :: 3.10",
2421
"Programming Language :: Python :: 3.11",
2522
"Programming Language :: Python :: 3.12",
23+
"Programming Language :: Python :: 3.13",
2624
"Topic :: Documentation",
2725
"Topic :: Utilities",
2826
]
2927

30-
requires-python = ">=3.8"
28+
requires-python = ">=3.11"
3129

3230
dependencies = ["Sphinx", "PyYAML", "defusedxml", "sphinxcontrib-runcmd"]
3331

0 commit comments

Comments
 (0)