Page MenuHomePhabricator

Fix tox installation on new Precise slaves
Closed, ResolvedPublic

Description

integration-slave-precise-1014 has been recreated but tox does not work:

hashar@integration-slave-precise-1014:~$ tox --version
Traceback (most recent call last):
  File "/usr/local/bin/tox", line 5, in <module>
    from pkg_resources import load_entry_point
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2707, in <module>
    working_set.require(__requires__)
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 686, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 584, in resolve
    raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: py>=1.4.17
hashar@integration-slave-precise-1014:~$
$ /usr/local/lib/python2.7/dist-packages/tox-1.9.2.egg-info/requires.txt 
virtualenv>=1.11.2
py>=1.4.17
$

Apparently py 1.4.30 has been installed:

$ ls -dl /usr/local/lib/python2.7/dist-packages/py*info
drwxr-sr-x 2 root staff 4096 Aug 26 09:21 /usr/local/lib/python2.7/dist-packages/py-1.4.30.dist-info

Event Timeline

hashar created this task.Aug 27 2015, 11:14 AM
hashar claimed this task.
hashar raised the priority of this task from to Needs Triage.
hashar updated the task description. (Show Details)

The slave has py-1.4.30.dist-info where as the other ones have py-1.4.26.egg-info (note the dist-info vs egg-info difference). I ran pip install py==1.4.26 and that installed it with an egg-info fixing the issue.

Then it fails with virtualenv, using the same trick did not work this time. The instance has virtualenv-12.1.1.dist-info whereas the others have egg-info.

Have to figure out why dist-info files are not recognized.

setuptools 0.6rc11 on Precise does not seem to support dist-info :-\

Change 234254 had a related patch set uploaded (by Hashar):
contint: upgrade setuptools from pypi

https://gerrit.wikimedia.org/r/234254

I fixed tox on the instance by installing setuptools from pypi.

It is probably time to migrate the tox jobs out of Precise.

hashar triaged this task as Normal priority.Aug 27 2015, 12:27 PM
hashar removed projects: Cloud-Services, Cloud-VPS.
hashar set Security to None.

Change 234254 merged by Giuseppe Lavagetto:
contint: upgrade setuptools from pypi

https://gerrit.wikimedia.org/r/234254

hashar closed this task as Resolved.Sep 21 2015, 7:56 PM

The puppet patch was already on the CI puppetmaster. It landed in puppet.git.

Since the dependencies are crazy, one wants to run:

pip install --upgrade setuptools