From d688a3bbe7cf92896bc0db4f2b867cfa8b42338c Mon Sep 17 00:00:00 2001 From: Malcolm Greaves Date: Fri, 2 Oct 2020 10:13:43 -0700 Subject: [PATCH] coremltools is python-dependent in requires_dist Makes the `coremltools` version explicitly dependent on the Python version in `install_requires` --- src/python/setup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/python/setup.py b/src/python/setup.py index 0dbd17b75a..5c6275f8fe 100644 --- a/src/python/setup.py +++ b/src/python/setup.py @@ -181,9 +181,9 @@ def do_not_install(require): if sys.version_info[0] == 3 and sys.version_info[1] == 8: # Only 4.0 betas support Python 3.8 - install_requires.append("coremltools==4.0b3") + install_requires.append("coremltools==4.0b3; python_version >= 3.8.0',") else: - install_requires.append("coremltools==3.3") + install_requires.append("coremltools==3.3; python_version < 3.8.0") if sys.platform == "darwin": install_requires.append("tensorflow >= 2.0.0")