src-d / hercules

Gaining advanced insights from Git repository history.
Other
2.63k stars 334 forks source link

Unable to "pip install labours" on Mac OSX Mojave #263

Closed manuel-koch closed 5 years ago

manuel-koch commented 5 years ago

I'm trying to install labours as suggested by the README:

My env is

manuelkoch [~/tmp]
$ python -c "import platform; print(platform.architecture())"
('64bit', '')

manuelkoch [~/tmp]
$ python --version
Python 3.6.4

manuelkoch [~/tmp]
$ python -m pip --version
pip 19.0.3 from /Users/manuelkoch/.pyenv/versions/hercules-3.6.4/lib/python3.6/site-packages/pip (python 3.6)
$ pip install labours
Collecting labours
  Using cached https://files.pythonhosted.org/packages/1f/9a/0bc624835472281121090d7ef0c1e274351709b897796a50a0662527a0d7/labours-10.0.0-py3-none-any.whl
Collecting clint<1.0,>=0.5.1 (from labours)
  Using cached https://files.pythonhosted.org/packages/3d/b4/41ecb1516f1ba728f39ee7062b9dac1352d39823f513bb6f9e8aeb86e26d/clint-0.5.1.tar.gz
Collecting protobuf<4.0,>=3.5.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/46/1e/c481d59760cded074d89ff51c99381708111c550ff698934cc296d27df2c/protobuf-3.7.1-cp36-cp36m-macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Collecting hdbscan<2.0,>=0.8.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/22/8d/1fc4bfd17ae871441fd6440abc3da5fdecf34831aa711e3e52727ab00556/hdbscan-0.8.19.tar.gz
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Collecting PyYAML<5.0,>=3.0 (from labours)
Collecting pandas<1.0,>=0.20.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/2a/67/0a59cb257c72bb837575ca0ddf5f0fe2a482e98209b7a1bed8cde68ddb46/pandas-0.24.2-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Collecting fastdtw<2.0,>=0.3.2 (from labours)
  Using cached https://files.pythonhosted.org/packages/fa/ef/a4cf2d72518b5fccd30284ba4d431fdb6266f72e75702ff05fd7c00b0b63/fastdtw-0.3.2.tar.gz
Collecting numpy<2.0,>=1.12.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/93/0e/30aaa357c3065957344b240482818eef31d4080f73dfa5f1ef7dcd8744d2/numpy-1.16.2-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Collecting munch<3.0,>=2.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/68/f4/260ec98ea840757a0da09e0ed8135333d59b8dfebe9752a365b04857660a/munch-2.3.2.tar.gz
Collecting scipy<2.0,>=0.19.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/f4/b1/6e0c995d7646b12112a721e93dc6316409cc4827c10ee309747f45ea6bfd/scipy-1.2.1-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Collecting python-dateutil<3.0,>=2.6.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/41/17/c62faccbfbd163c7f57f3844689e3a78bae1f403648a6afb1d0866d87fbb/python_dateutil-2.8.0-py2.py3-none-any.whl
Collecting seriate<2.0,>=1.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/92/cf/daa128c0df2d021620599ccd4d83d98983b1c616e25bfbf9f113c12cee62/seriate-1.0.0-py3-none-any.whl
Collecting matplotlib<4.0,>=2.0 (from labours)
  Using cached https://files.pythonhosted.org/packages/82/7e/184d995d711e3401722769cd6982b46d42aee14a82ba54a3a79425f939c9/matplotlib-3.0.3-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Collecting args (from clint<1.0,>=0.5.1->labours)
  Using cached https://files.pythonhosted.org/packages/e5/1c/b701b3f4bd8d3667df8342f311b3efaeab86078a840fb826bd204118cc6b/args-0.1.0.tar.gz
Requirement already satisfied: setuptools in /Users/manuelkoch/.pyenv/versions/3.6.4/envs/hercules-3.6.4/lib/python3.6/site-packages (from protobuf<4.0,>=3.5.0->labours) (28.8.0)
Collecting six>=1.9 (from protobuf<4.0,>=3.5.0->labours)
  Using cached https://files.pythonhosted.org/packages/73/fb/00a976f728d0d1fecfe898238ce23f502a721c0ac0ecfedb80e0d88c64e9/six-1.12.0-py2.py3-none-any.whl
Collecting scikit-learn>=0.17 (from hdbscan<2.0,>=0.8.0->labours)
  Downloading https://files.pythonhosted.org/packages/7e/90/bfe484adb16cdad078967b2b480517ec6c1180137e26fb4b015bcb090226/scikit_learn-0.20.3-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (8.0MB)
    100% |████████████████████████████████| 8.0MB 2.0MB/s
Collecting cython>=0.27 (from hdbscan<2.0,>=0.8.0->labours)
  Using cached https://files.pythonhosted.org/packages/d0/27/d7e796420dd1c69135ccf1362cd8ecf61a09db990a8335d65cd715b275b6/Cython-0.29.6-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl
Collecting pytz>=2011k (from pandas<1.0,>=0.20.0->labours)
  Downloading https://files.pythonhosted.org/packages/61/28/1d3920e4d1d50b19bc5d24398a7cd85cc7b9a75a490570d5a30c57622d34/pytz-2018.9-py2.py3-none-any.whl (510kB)
    100% |████████████████████████████████| 512kB 26.4MB/s
Collecting ortools>=6.9.5824 (from seriate<2.0,>=1.0->labours)
  Could not find a version that satisfies the requirement ortools>=6.9.5824 (from seriate<2.0,>=1.0->labours) (from versions: 6.5.4527, 6.6.4656, 6.6.4659, 6.7.4957, 6.7.4973)
No matching distribution found for ortools>=6.9.5824 (from seriate<2.0,>=1.0->labours)

Any help appreciated !

vmarkovtsev commented 5 years ago

@manuel-koch The error is about installing ortools. The versions which your pip suggests are quite old, because the most recent one is 7.0.6546. Clear pip cache? Sometimes it is stuck.

vmarkovtsev commented 5 years ago

Closing this since this is a problem with a third-party package.

manuel-koch commented 5 years ago

Hm... pip install --no-cache-dir labours failed with same error. Anything else I can try ?

manuel-koch commented 5 years ago

Seems like the latest version of ortools is not available for my environment:

manuelkoch [~/tmp]
$ pip search ortools
ortools (7.0.6546)       - Google OR-Tools python libraries and modules

manuelkoch [~/tmp]
$ pip install ortools
Collecting ortools
  Downloading https://files.pythonhosted.org/packages/08/93/f3f35a5023a9b54d945f67a97e92e1d365ffa629e3eae1751963be03cc9c/ortools-6.7.4973-cp36-cp36m-macosx_10_13_x86_64.whl (7.6MB)
    100% |████████████████████████████████| 7.6MB 4.6MB/s
Collecting six>=1.10 (from ortools)
  Downloading https://files.pythonhosted.org/packages/73/fb/00a976f728d0d1fecfe898238ce23f502a721c0ac0ecfedb80e0d88c64e9/six-1.12.0-py2.py3-none-any.whl
Collecting protobuf>=3.5.1 (from ortools)
  Downloading https://files.pythonhosted.org/packages/46/1e/c481d59760cded074d89ff51c99381708111c550ff698934cc296d27df2c/protobuf-3.7.1-cp36-cp36m-macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (1.3MB)
    100% |████████████████████████████████| 1.3MB 11.6MB/s
Requirement already satisfied: setuptools in /Users/manuelkoch/.pyenv/versions/3.6.4/envs/hercules-3.6.4/lib/python3.6/site-packages (from protobuf>=3.5.1->ortools) (28.8.0)
Installing collected packages: six, protobuf, ortools
Successfully installed ortools-6.7.4973 protobuf-3.7.1 six-1.12.0

manuelkoch [~/tmp]
$ pip install ortools==7.0.6546
Collecting ortools==7.0.6546
  Could not find a version that satisfies the requirement ortools==7.0.6546 (from versions: 6.5.4527, 6.6.4656, 6.6.4659, 6.7.4957, 6.7.4973)
No matching distribution found for ortools==7.0.6546
manuel-koch commented 5 years ago

Created a ticket in ortools: https://github.com/google/or-tools/issues/1164

manuel-koch commented 5 years ago

ortools doesn't seem to support Python 3.6 ( on Mac OSX ) currently.

vmarkovtsev commented 5 years ago

@manuel-koch I will set the lower bound to 6.7.4973, hope it will help.

vmarkovtsev commented 5 years ago

Done. seriate==1.0.1 has been published, you can force it by pip install seriate==1.0.1 and then labours should install.

manuel-koch commented 5 years ago

Thanks ! That fixed my install problem :-)

manuel-koch commented 5 years ago

The issue has been resolved in ortools too ( see ticket mentioned above ), thus your workaround may not be needed for python 3.6.4. With latest ortools package I was able to install labours without your suggested workaround from scratch. Anyway thanks for your quick response !