rapidsai / dask-cudf

[ARCHIVED] Dask support for distributed GDF object --> Moved to cudf
https://github.com/rapidsai/cudf
Apache License 2.0
136 stars 58 forks source link

[BUG] dask_cudf __version__ is using cudf __version__ #296

Closed pradghos closed 5 years ago

pradghos commented 5 years ago

Currently dask_cudf version is using with cudf version - which is probably not correct -

https://github.com/rapidsai/dask-cudf/blob/b566ab60ea69e6e165533b68b1966875528afb06/dask_cudf/__init__.py#L13

here is the problem - consider a scenario when dask-cudf and cudf are in different version.

>>> import dask_cudf
>>> print(dask_cudf.__version__)
0.7.2+0.g3ebd286.dirty          -------------------> This is not correct.
>>> import cudf
>>> print(cudf.__version__)
0.7.2+0.g3ebd286.dirty
>>>
(base) [builder@d065228d37d1 ~]$ conda list | grep dask-cudf
dask-cudf                 0.8.0a           py36h33ca993_0    local
(base) [builder@d065228d37d1 ~]$

Fix for the issue -

diff --git a/dask_cudf/__init__.py b/dask_cudf/__init__.py
index 9b4af16..bf2b5c9 100644
--- a/dask_cudf/__init__.py
+++ b/dask_cudf/__init__.py
@@ -8,9 +8,9 @@ from .core import (
 )
 from .io import read_csv, read_orc, read_json, read_parquet
 from . import backends
-
 import cudf
-from cudf._version import get_versions
+
+from ._version import get_versions

 __version__ = get_versions()["version"]
 del get_versions
diff --git a/setup.py b/setup.py
index 42dd2c6..3a35b85 100644
--- a/setup.py
+++ b/setup.py
@@ -2,15 +2,17 @@ import os
 from codecs import open

 from setuptools import find_packages, setup
+import versioneer
+

 # Get the long description from the README file
 with open(os.path.join(os.path.dirname(__file__), "README.md")) as f:
     long_description = f.read()

-version = os.environ.get("GIT_DESCRIBE_TAG", "0.0.0.dev0").lstrip("v")
 setup(
     name="dask-cudf",
-    version=version,
+    version=versioneer.get_version(),
+    cmdclass=versioneer.get_cmdclass(),
     description="Utilities for Dask and cuDF interactions",
     long_description=long_description,
     long_description_content_type="text/markdown",

@kkraus14 @mrocklin Please let me know If I can create a PR for the same. Thank you !

mrocklin commented 5 years ago

I think that the plan is to merge dask-cudf into cudf in the next release, so this problem should go away.

On Fri, Jun 28, 2019 at 8:03 AM Pradipta Ghosh notifications@github.com wrote:

Currently dask_cudf version is using with cudf version - which is probably not correct -

https://github.com/rapidsai/dask-cudf/blob/b566ab60ea69e6e165533b68b1966875528afb06/dask_cudf/__init__.py#L13

here is the problem - consider a scenario when dask-cudf and cudf are in different version.

import dask_cudf print(dask_cudf.version) 0.7.2+0.g3ebd286.dirty -------------------> This is not correct. import cudf print(cudf.version) 0.7.2+0.g3ebd286.dirty

(base) [builder@d065228d37d1 ~]$ conda list | grep dask-cudf dask-cudf 0.8.0a py36h33ca993_0 local (base) [builder@d065228d37d1 ~]$

Fix for the issue -

git diff diff --git a/dask_cudf/init.py b/dask_cudf/init.py index 9b4af16..bf2b5c9 100644 --- a/dask_cudf/init.py +++ b/dask_cudf/init.py @@ -8,9 +8,9 @@ from .core import ( ) from .io import read_csv, read_orc, read_json, read_parquet from . import backends

import cudf -from cudf._version import get_versions + +from ._version import get_versions

version = get_versions()["version"] del get_versions diff --git a/setup.py b/setup.py index 42dd2c6..3a35b85 100644 --- a/setup.py +++ b/setup.py @@ -2,15 +2,17 @@ import os from codecs import open

from setuptools import find_packages, setup +import versioneer +

Get the long description from the README file

with open(os.path.join(os.path.dirname(file), "README.md")) as f: long_description = f.read()

-version = os.environ.get("GIT_DESCRIBE_TAG", "0.0.0.dev0").lstrip("v") setup( name="dask-cudf",

  • version=version,
  • version=versioneer.get_version(),
  • cmdclass=versioneer.get_cmdclass(), description="Utilities for Dask and cuDF interactions", long_description=long_description, long_description_content_type="text/markdown",

@kkraus14 https://github.com/kkraus14 @mrocklin https://github.com/mrocklin Please let me know If I can create a PR for the same. Thank you !

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/rapidsai/dask-cudf/issues/296?email_source=notifications&email_token=AACKZTHDAAKR3KRORU62SSTP4WZV5A5CNFSM4H4CXNG2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4G4H4I2Q, or mute the thread https://github.com/notifications/unsubscribe-auth/AACKZTF6M4NRQJ7LQLXRDP3P4WZV5ANCNFSM4H4CXNGQ .

pradghos commented 5 years ago

@mrocklin : Thanks for the response - is the merger planned for - v0.9.0 release ?

quasiben commented 5 years ago

@kkraus14 just finished the merge: https://github.com/rapidsai/cudf/pull/2160

should we close this now ?

pradghos commented 5 years ago

@kkraus14 just finished the merge: rapidsai/cudf#2160

should we close this now ?

Sure . Thanks for the information !