Pip: Missing distribution specification. How to fix it?

When executing this command on my virtual machine, the following error appears:

$ sudo pip install -U -v --no-deps -b /tmp/piyush/ /tmp/piyush/common_bundle

  File "/usr/local/lib/python2.7/dist-packages/pip-6.0.6-py2.7.egg/pip/_vendor/pkg_resources/__init__.py", line 2807, in parse_requirements
    raise ValueError("Missing distribution spec", line)
ValueError: ('Missing distribution spec', '/tmp/piyush/common_bundle')

My input file is an archive.

$ file common_bundle
common_bundle: Zip archive data, at least v2.0 to extract

Pip version:

$ pip -V
pip 6.0.6 from /usr/local/lib/python2.7/dist-packages/pip-6.0.6-py2.7.egg (python 2.7)

Here is the pip manifest present in common_bundle:

# This is a pip bundle file, that contains many source packages
# that can be installed as a group.  You can install this like:
#     pip this_file.zip
# The rest of the file contains a list of all the packages included:
PyYAML==3.10
boto==2.6.0
msgpack-python==0.2.2
tornado==2.1.1
ujson==1.22
virtualenv==1.8.2
bottle==0.10.7
raven==2.0.3
protobuf==2.4.1
# These packages were installed to satisfy the above requirements:
simplejson==2.4.0
distribute==0.6.32

Does anything look suspicious?

Thank.

+5
source share
2 answers

When pipinstalled from an archive, the file must have the appropriate extension or you need to use the protocol explicitly file://. Rename the file to /tmp/piyush/common_bundle.zipor use file:///tmp/piyush/common_bundle.

The error you see has nothing to do with the contents of the archive, I piphave not yet unpacked it.

0
source

, . . , .

0

Source: https://habr.com/ru/post/1570738/


All Articles