Skip to content

Commit 08acfb6

Browse files
committed
doc: Import openslide._version from path added to sys.path
Import _version directly out of the package directory, rather than changing the path we add to sys.path. That way we can avoid loading openslide/__init__.py, which will fail if OpenSlide is not installed (as when building a downstream package).
1 parent d9a7562 commit 08acfb6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

doc/conf.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,11 @@
5252
# |version| and |release|, also used in various other places throughout the
5353
# built documents.
5454
#
55-
import openslide._version
55+
import _version
5656
# The short X.Y version.
57-
version = openslide._version.__version__
57+
version = _version.__version__
5858
# The full version, including alpha/beta/rc tags.
59-
release = openslide._version.__version__
59+
release = _version.__version__
6060

6161
# The language for content autogenerated by Sphinx. Refer to documentation
6262
# for a list of supported languages.

0 commit comments

Comments
 (0)