File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change 22This package provides the numpydoc Sphinx extension for handling docstrings
33formatted according to the NumPy documentation format.
44"""
5- __version__ = '1.2.2.dev0'
5+ from . _version import __version__
66
77
88def _verify_sphinx_jinja ():
Original file line number Diff line number Diff line change 1+ __version__ = '1.2.2.dev0'
Original file line number Diff line number Diff line change 33
44from setuptools import setup
55
6- from numpydoc import __version__ as version
6+ # Adapted from MNE-Python (BSD)
7+ version = None
8+ with open (os .path .join ('numpydoc' , '_version.py' )) as fid :
9+ for line in (line .strip () for line in fid ):
10+ if line .startswith ('__version__' ):
11+ version = line .split ('=' )[1 ].strip ().strip ('\' ' )
12+ break
13+ if version is None :
14+ raise RuntimeError ('Could not determine version' )
715
816if sys .version_info < (3 , 7 ):
917 raise RuntimeError ("Python version >= 3.7 required." )
You can’t perform that action at this time.
0 commit comments