| 1 |
From: Ole Streicher <[email protected]> |
| 2 |
Date: Fri, 27 Oct 2023 12:53:11 +0200 |
| 3 |
Subject: Directly take the version from the package |
| 4 |
|
| 5 |
--- |
| 6 |
docs/conf.py | 3 +-- |
| 7 |
1 file changed, 1 insertion(+), 2 deletions(-) |
| 8 |
|
| 9 |
diff --git a/docs/conf.py b/docs/conf.py |
| 10 |
index f971ddd..341fd6b 100644 |
| 11 |
--- a/docs/conf.py |
| 12 |
+++ b/docs/conf.py |
| 13 |
@@ -14,7 +14,6 @@ |
| 14 |
from configparser import ConfigParser |
| 15 |
import sys |
| 16 |
import datetime |
| 17 |
-from importlib import metadata |
| 18 |
|
| 19 |
try: |
| 20 |
from sphinx_astropy.conf.v2 import * # noqa |
| 21 |
@@ -78,7 +77,7 @@ package = sys.modules[project] |
| 22 |
# built documents. |
| 23 |
|
| 24 |
# The full version, including alpha/beta/rc tags. |
| 25 |
-release = metadata.version(project) |
| 26 |
+release = package.__version__ |
| 27 |
# The short X.Y version. |
| 28 |
version = ".".join(release.split(".")[:2]) |
| 29 |
|