Skip to content

Commit 7642576

Browse files
committed
move version detection before deprecation modules
1 parent ed7c526 commit 7642576

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

pandas/__init__.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,12 @@
5757
from pandas.io.api import *
5858
from pandas.util._tester import test
5959

60+
# use the closest tagged version if possible
61+
from ._version import get_versions
62+
v = get_versions()
63+
__version__ = v.get('closest-tag', v['version'])
64+
del get_versions, v
65+
6066
# extension module deprecations
6167
from pandas.util.depr_module import _DeprecatedModule
6268

@@ -65,12 +71,6 @@
6571
lib = _DeprecatedModule(deprmod='pandas.lib', deprmodto='pandas._libs.lib')
6672
tslib = _DeprecatedModule(deprmod='pandas.tslib', deprmodto='pandas._libs.tslib')
6773

68-
# use the closest tagged version if possible
69-
from ._version import get_versions
70-
v = get_versions()
71-
__version__ = v.get('closest-tag', v['version'])
72-
del get_versions, v
73-
7474
# module level doc-string
7575
__doc__ = """
7676
pandas - a powerful data analysis and manipulation library for Python

0 commit comments

Comments
 (0)