keenlabs / KeenClient-Python

Official Python client for the Keen IO API. Build analytics features directly into your Python apps.
https://keen.io/docs
MIT License
133 stars 58 forks source link

Travis CI fails installing pycryptodome on Python 3.2 #126

Closed masojus closed 7 years ago

masojus commented 7 years ago

On 4/18/17, against commit 476c00f, the 3.2 job worked just fine:

$ pip install -r requirements.txt
Collecting pycryptodome>=3.4 (from -r requirements.txt (line 1))
  Downloading pycryptodome-3.4.5.tar.gz (6.5MB)
    100% |¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦| 6.5MB 77kB/s 
Collecting requests<2.11.0,>=2.5 (from -r requirements.txt (line 2))
  Downloading requests-2.10.0-py2.py3-none-any.whl (506kB)
    100% |¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦???¦¦¦¦| 507kB 1.1MB/s 
Requirement already satisfied (use --upgrade to upgrade): six~=1.10.0 in /home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages (from -r requirements.txt (line 3))
Building wheels for collected packages: pycryptodome
  Running setup.py bdist_wheel for pycryptodome
  Stored in directory: /home/travis/.cache/pip/wheels/82/80/08/e4cb0e06e4df5c5104899de9018e1829683c28c0ee9c45f4a1
Successfully built pycryptodome
Installing collected packages: pycryptodome, requests
Successfully installed pycryptodome-3.4.5 requests-2.10.0
$ python setup.py test

...but then with no changes, on 5/16/17, against commit 6a13679, the 3.2 job failed while installing pycryptodome:

$ pip install -r requirements.txt
Collecting pycryptodome>=3.4 (from -r requirements.txt (line 1))
  Downloading pycryptodome-3.4.5.tar.gz (6.5MB)
    100% |████████████████████████████████| 6.5MB 81kB/s 
Exception:
Traceback (most recent call last):
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/basecommand.py", line 211, in main
    status = self.run(options, args)
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/commands/install.py", line 305, in run
    wb.build(autobuilding=True)
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/wheel.py", line 705, in build
    self.requirement_set.prepare_files(self.finder)
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/req/req_set.py", line 334, in prepare_files
    functools.partial(self._prepare_file, finder))
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/req/req_set.py", line 321, in _walk_req_to_install
    more_reqs = handler(req_to_install)
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/req/req_set.py", line 505, in _prepare_file
    abstract_dist.prep_for_dist()
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/req/req_set.py", line 123, in prep_for_dist
    self.req_to_install.run_egg_info()
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/req/req_install.py", line 376, in run_egg_info
    self.setup_py, self.name,
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pip/req/req_install.py", line 347, in setup_py
    import setuptools  # noqa
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/setuptools/__init__.py", line 12, in <module>
    import setuptools.version
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/setuptools/version.py", line 1, in <module>
    import pkg_resources
  File "/home/travis/virtualenv/python3.2.6/lib/python3.2/site-packages/pkg_resources/__init__.py", line 77, in <module>
    raise RuntimeError("Python 3.3 or later is required")
RuntimeError: Python 3.3 or later is required
The command "pip install -r requirements.txt" failed and exited with 2 during .

There is also a new note from Travis that says this environment changed in this timeframe: This job ran on our Precise, sudo: required environment which was updated on May 4th. Please check our blog for more details about this update. The blog entry is here in case that turns out to be pertinent.

I tried changing pip versions on the fly and using different versions of pycryptodome and such, to no avail. In the meantime, we'll have to remove 3.2 from the list of Python versions we test against, and revisit this down the road.

baumatron commented 7 years ago

I think this issue and corresponding change probably just made it into the travis image and that's what broke us. Seems like an option is to install setuptools < 30.

baumatron commented 7 years ago

This change will fix the failure by installing setuptools<30 for Python 3.2 if we decide to continue support: https://github.com/keenlabs/KeenClient-Python/commit/9c16734d34773910a1935f203b33f50b800e76ae

masojus commented 7 years ago

Thanks @baumatron! I'll keep it for now and open a bug so we can have a larger discussion about 3.2 support.

masojus commented 7 years ago

I incorporated @baumatron's change with 6befef0 so 3.2 testing is alive as it stands today. Closing this Issue.