This is an automated email from the ASF dual-hosted git repository.

altay pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git


The following commit(s) were added to refs/heads/master by this push:
     new c14c975  [BEAM-4752] Add support for newer dill dependency (#5931)
c14c975 is described below

commit c14c975224af417dcdc74fed8b0d893be742e9d7
Author: Ahmet Altay <[email protected]>
AuthorDate: Fri Jul 13 08:52:39 2018 -0700

    [BEAM-4752] Add support for newer dill dependency (#5931)
    
    * Add support for newer dill dependency
---
 sdks/python/apache_beam/internal/pickler.py | 6 ++++++
 sdks/python/setup.py                        | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/sdks/python/apache_beam/internal/pickler.py 
b/sdks/python/apache_beam/internal/pickler.py
index 3a04d8c..a4d20b9 100644
--- a/sdks/python/apache_beam/internal/pickler.py
+++ b/sdks/python/apache_beam/internal/pickler.py
@@ -39,6 +39,12 @@ import zlib
 
 import dill
 
+# Dill 0.28.0 renamed dill.dill to dill._dill:
+# 
https://github.com/uqfoundation/dill/commit/f0972ecc7a41d0b8acada6042d557068cac69baa
+# TODO: Remove this once Beam depends on dill >= 0.2.8
+if not getattr(dill, 'dill', None):
+  dill.dill = dill._dill
+
 
 def _is_nested_class(cls):
   """Returns true if argument is a class object that appears to be nested."""
diff --git a/sdks/python/setup.py b/sdks/python/setup.py
index 110228a..46c8050 100644
--- a/sdks/python/setup.py
+++ b/sdks/python/setup.py
@@ -97,7 +97,7 @@ else:
 REQUIRED_PACKAGES = [
     'avro>=1.8.1,<2.0.0',
     'crcmod>=1.7,<2.0',
-    'dill==0.2.6',
+    'dill>=0.2.6,<=0.2.8.2',
     'grpcio>=1.8,<2',
     'hdfs>=2.1.0,<3.0.0',
     'httplib2>=0.8,<=0.11.3',

Reply via email to