The error below happens every time I increase the version number in my Python app. It’s trying to uninstall the old version of my app from the cached Python environment. Clearing the cache fixes the problem, but only until the next version bump. This problem only happens in Circle. Tests run fine locally.
Traceback (most recent call last):
File "/home/ubuntu/virtualenvs/venv-system/bin/pip", line 11, in <module>
sys.exit(main())
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/__init__.py", line 217, in main
return command.main(cmd_args)
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/basecommand.py", line 246, in main
pip_version_check(session)
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/utils/outdated.py", line 102, in pip_version_check
installed_version = get_installed_version("pip")
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/utils/__init__.py", line 848, in get_installed_version
working_set = pkg_resources.WorkingSet()
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 626, in __init__
self.add_entry(entry)
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 682, in add_entry
for dist in find_distributions(entry, True):
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 2080, in find_eggs_in_zip
if metadata.has_metadata('PKG-INFO'):
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 1610, in has_metadata
return self.egg_info and self._has(self._fn(self.egg_info, name))
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 1968, in _has
return zip_path in self.zipinfo or zip_path in self._index()
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 1848, in zipinfo
return self._zip_manifests.load(self.loader.archive)
File "/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 1788, in load
mtime = os.stat(path).st_mtime
OSError: [Errno 2] No such file or directory: '/home/ubuntu/virtualenvs/venv-system/local/lib/python2.7/site-packages/hpx_voltron-0.0.5-py2.7.egg'
if [ -e requirements.txt ]; then pip install -r requirements.txt;else pip install -r requirements.pip;fi returned exit code 1
Action failed: pip install