Don't try to use git to find the version number
authorDebian Science Team <debian-science-maintainers@lists.alioth.debian.org>
Wed, 26 Aug 2020 21:34:50 +0000 (22:34 +0100)
committerRebecca N. Palmer <rebecca_palmer@zoho.com>
Wed, 26 Aug 2020 21:34:50 +0000 (22:34 +0100)
Needed as Debian buildds use tarballs

Author: Yaroslav Halchenko
Forwarded: not-needed

Gbp-Pq: Name deb_nonversioneer_version.patch

pandas/__init__.py
pandas/tests/api/test_api.py
pandas/tests/test_common.py

index 6eda468eed23ac69080eac24ceeb677d3113d0f4..0eefab4b3d486983ce1bb1ae37fb104865a6a536 100644 (file)
@@ -180,13 +180,7 @@ from pandas.util._tester import test
 import pandas.testing
 import pandas.arrays
 
-# use the closest tagged version if possible
-from ._version import get_versions
-
-v = get_versions()
-__version__ = v.get("closest-tag", v["version"])
-__git_version__ = v.get("full-revisionid")
-del get_versions, v
+from .__version import version as __version__
 
 # GH 27101
 # TODO: remove Panel compat in 1.0
index 5aab5b814bae737dd00e405e52c99a0ba9df46f5..85efac456d2d387317fb62897592d05afb2c4e42 100644 (file)
@@ -202,7 +202,7 @@ class TestPDApi(Base):
         "_testing",
         "_tslib",
         "_typing",
-        "_version",
+# not in Debian        "_version",
     ]
 
     def test_api(self):
index a8a0fcea7182c50db1e9b6e8196a47c1220e7daa..5f2c85c544f0cdf2ca559dd63ae4277c0d858714 100644 (file)
@@ -113,7 +113,7 @@ def test_standardize_mapping():
     dd = collections.defaultdict(list)
     assert isinstance(com.standardize_mapping(dd), partial)
 
-
+@pytest.mark.xfail(reason="deb_nonversioneer_version patch")
 def test_git_version():
     # GH 21295
     git_version = pd.__git_version__