1

we want to use pip in order to install - MarkupSafe-1.1.0-cp27-cp27m-manylinux1_x86_64.whl

from uname -a we have

 uname -a
Linux Master 3.10.0-327.el7.x86_64 #1 SMP Thu Oct 29 17:29:29 EDT 2015 x86_64 x86_64 x86_64 GNU/Linux

so we download the pkg - MarkupSafe-1.1.0-cp27-cp27m-manylinux1_x86_64.whl

and installing it

pip install -v --no-index --find-links PIP/ MarkupSafe-1.1.0-cp27-cp27m-manylinux1_x86_64.whl
Ignoring indexes: https://pypi.python.org/simple
Requirement 'MarkupSafe-1.1.0-cp27-cp27m-manylinux1_x86_64.whl' looks like a filename, but the file does not exist
MarkupSafe-1.1.0-cp27-cp27m-manylinux1_x86_64.whl is not a supported wheel on this platform.
Exception information:
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/pip/basecommand.py", line 223, in main
    status = self.run(options, args)
  File "/usr/lib/python2.7/site-packages/pip/commands/install.py", line 278, in run
    wheel_cache
  File "/usr/lib/python2.7/site-packages/pip/basecommand.py", line 275, in populate_requirement_set
    wheel_cache=wheel_cache
  File "/usr/lib/python2.7/site-packages/pip/req/req_install.py", line 197, in from_line
    wheel.filename
UnsupportedWheel: MarkupSafe-1.1.0-cp27-cp27m-manylinux1_x86_64.whl is not a supported wheel on this platform.

but why we get - is not a supported wheel on this platform.

what is not right here , ?

shalom
  • 461
  • 13
  • 29

1 Answers1

0

This is most likely an issue with conflicting python versions. The 'cp27' in the wheel name indicates that it should be installed with CPython 2.7, while your pip may only support python 3.x.

To check this, open the REPL (either with $ python or $ python3) and run these two commands:

>>> import pip

>>> pip.pep425tags.get_supported()

It should display the formats acceptable for a pip install, similar to this:

[('cp36', 'cp36m', 'linux_armv7l'), ('cp36', 'abi3', 'linux_ar7l'), ('cp36', 'none', 'linux_armv7l'), ('cp35', 'abi3', 'linuarmv7l'), ('cp34', 'abi3', 'l inux_armv7l'), ('cp33', 'abi3', 'linux_armv7l'), ('cp32', 'abi3', 'linux_ar7l'), ('py3', 'none', 'linux_armv7l'), ('cp36', 'none', 'any')('cp3', 'none', 'any'), ('py36', 'none', 'any'), ('py3', 'none', 'any'), ('py35', 'none', 'any'), ('py34', 'none', 'any, ('py33', 'none', 'any'), ('py32', 'none', 'any') , ('py31', 'ne', 'any'), ('py30', 'none', 'any')]

Simply go back to the Pypi downloads page for Markupsafe then and find the suitable wheel release for your platform.

Alternative problems:

  • You're working on a 32-bit architecture (only 32-bit support for Windows, sadly)
  • Your python implementation isn't CPython (can check this by importing platform, then >>> platform.python_implementation()
  • 1
    It's CentOS 7; it is CPython 2.7. The traceback shows a python2.7 version of pip being called. I see nothing indicating python3 is even involved at all. – Michael Hampton Jan 07 '19 at 01:24