summaryrefslogtreecommitdiff
path: root/sphinx/ext/autodoc/preserve_defaults.py
diff options
context:
space:
mode:
authorAdam Turner <9087854+aa-turner@users.noreply.github.com>2022-09-28 15:17:46 +0100
committerAdam Turner <9087854+aa-turner@users.noreply.github.com>2022-09-30 19:10:48 +0100
commit7765940f14201f03aed1038d644bd80289ad672f (patch)
tree6d4a2eab02c298723182c8f47860d0c510354fe2 /sphinx/ext/autodoc/preserve_defaults.py
parent29060711984f9ad6be210d9a237a5f5cd5bce5c9 (diff)
downloadsphinx-git-7765940f14201f03aed1038d644bd80289ad672f.tar.gz
Ensure non-builtin extensions use the proper version
Diffstat (limited to 'sphinx/ext/autodoc/preserve_defaults.py')
-rw-r--r--sphinx/ext/autodoc/preserve_defaults.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/sphinx/ext/autodoc/preserve_defaults.py b/sphinx/ext/autodoc/preserve_defaults.py
index a12f42fcf..5ae3f3593 100644
--- a/sphinx/ext/autodoc/preserve_defaults.py
+++ b/sphinx/ext/autodoc/preserve_defaults.py
@@ -10,6 +10,7 @@ import sys
from inspect import Parameter
from typing import Any, Dict, List, Optional
+import sphinx
from sphinx.application import Sphinx
from sphinx.locale import __
from sphinx.pycode.ast import parse as ast_parse
@@ -121,6 +122,6 @@ def setup(app: Sphinx) -> Dict[str, Any]:
app.connect('autodoc-before-process-signature', update_defvalue)
return {
- 'version': '1.0',
+ 'version': sphinx.__display_version__,
'parallel_read_safe': True
}