when you recently deployed a project, the PIP install requirements required a pygraphviz package. This package is for graphical data.
requirements
requirements
requirements
requirements
requirements
requirements
requirements
is the associated error message as shown below.
error: Microsoft Visual C++ 10.0 is required. Get it with "Microsoft Windows SDK 7.1": www.microsoft.com/download/details.aspx?id=8279
----------------------------------------
Failed building wheel for pygraphviz
Running setup.py clean for pygraphviz
Successfully built dominate Flask-Bootstrap flask-nav Flask-Uploads itsdangerous MarkupSafe visitor
Failed to build pygraphviz
Installing collected packages: appdirs, chardet, click, dominate, MarkupSafe, Jinja2, itsdangerous, Werkzeug, Flask, visitor, Flask-Bootstrap, Flask-Login, flask-nav, Flask-Uploads, WTForms, Flask-WTF, gunicorn, iso8601, numpy, pyparsing, six, packaging, pytz, requests, decorator, networkx, graphviz, pygraphviz
Running setup.py install for pygraphviz ... error
Complete output from command f:\fiat_dev\venv\scripts\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\JIANGM~1.FNS\\AppData\\Local\\Temp\\pip-install-b3cfvse8\\pygraphviz\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\JIANGM~1.FNS\AppData\Local\Temp\pip-record-h2160l90\install-record.txt --single-version-externally-managed --compile --install-headers f:\fiat_dev\venv\include\site\python3.4\pygraphviz:
...
running build_ext
building 'pygraphviz._graphviz' extension
error: Microsoft Visual C++ 10.0 is required. Get it with "Microsoft Windows SDK 7.1": www.microsoft.com/download/details.aspx?id=8279
----------------------------------------
Command "f:\fiat_dev\venv\scripts\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\JIANGM~1.FNS\\AppData\\Local\\Temp\\pip-install-b3cfvse8\\pygraphviz\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\JIANGM~1.FNS\AppData\Local\Temp\pip-record-h2160l90\install-record.txt --single-version-externally-managed --compile --install-headers f:\fiat_dev\venv\include\site\python3.4\pygraphviz" failed with error code 1 in C:\Users\JIANGM~1.FNS\AppData\Local\Temp\pip-install-b3cfvse8\pygraphviz\
in normal fashion, I started Posting this error message to Google. Found some so-called solutions, including pyGraphviz’s Github community, and other blog posts. The solution:
1. Let you install graphviz, then set the environment variable. Then specify at installation time a parameter such as Pip’s inlude path
2. Let you install a 32-bit python, then go to 1, recompile and install pygraphviz
3. Just get out of Windows Binaries for Python Extension Packages.
I’ve tried all of the above solutions. However, when I was compiling, there were a lot of c compilation errors. Format conversion errors and so on. doesn’t solve the real problem . I feel suspicious, these posts on the Net clearly say that doing so can solve ah!
when I received a useful message saying that pygraphviz does not support python3.4 or above . So I reinstalled Python 3.4 and changed the system’s Python environment variable. When I re-installed PIP Install Pygraphviz-xxx-.whl in the CMD, I was notified that the installation was successful.
but for this project I used vitrualenv to manage the packages it needed. I just wrapped this in the system Python library. So I activate the current venv,
and run PIP install pygraphviz-xxx-.whl again, a familiar error message appears:
(venv) F:\pygraphviz-1.3.1>pip install pygraphviz-1.3.1-cp34-none-win_amd64.whl
pygraphviz-1.3.1-cp34-none-win_amd64.whl is not a supported wheel on this platform.
You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
wait, didn’t you just install it?What’s the problem?
after some thinking, I found that the virtual python environment built in venv was set up a week ago. At that time, the python version of the system was 3.5.
, so the python version in this virtual environment was also 3.5. So the installation failed. To prove my point, I deleted Venv, re-opened a CMD, and reinstalled a virtual environment.
when I type PIP install pygraphviz-xxx-.whl again, the command line indicates that the installation was successful.
WHL is not a supported wheel on this platform.
is not supported on this platform. WHL is not a supported wheel on this platform. I always thought this meant that this version of the WHL file was not supported by my system version. Now, in retrospect, what it’s really saying is, the Python version doesn’t support, right?
and the last thing to notice is
pygraphviz package can be used on the premise that the software graphviz has been installed on the system, visit the official website to download the installation package, and install it. After installation, add the bin directory to the system path.
to summarize:
- pygraphviz does not support python3.4 or above,
when you install this package, try switching to a lower version of python - venv the python environment is based on the system python version,
but after venv is installed, It is to some extent independent of the system python - is not a supported wheel on this platform
platform is not only the operating system platform, but also the development environment, etc.
is also attached to install pygraphviz may useful connection :
-
installation steps in detail reference post: https://blog.csdn.net/churximi/article/details/51059285 p> li>
-
Unofficial Windows Binaries for Python Extension Packages p> li> ul>
and finally, good luck ~
Read More:
- Error code is 2502 / 2503 when installing MSI format installation package under win10 or win8
- Error 2052/2053 when installing node.js in win
- Problems and solutions of installing Ubuntu 12.04 in win7
- Installing xgboost in anaconda is based on win10 32 / 64 bit system
- The experience of installing OpenGL in vs2017 under win7 system
- Configuring OpenGL development environment in win10 + vs2015 (including the method of installing 32-bit and 64 bit libraries)
- Error installing NX10.0 in win10. Tip: ZeroGu6: Windows DLL failed to load
- runtime error program:c :\windows\ explorer.exe (appears after installing the win8 security update) why?
- Some problems in installing wsl2 and NVIDIA docker in win10
- Win10 install iTunes appears: “installation assembly microsoft.VC80 . CRT, tupe = Win32, version = 8.0.50727.6195 “…”
- Importerror: DLL load failed while importing win32gui: 1 is not a valid Win32 Application.
- Visual SVN server provider failed to perform the attempted operation 0x80041024 after win7 upgraded win10
- Solution to the error of win7 & win10 shared printer 0x000000709
- Re installing Android studio always fails to install SDK when installing software (solution)
- ARP – s in win7 (ARP binding under win7)
- Solve the problem of installing APK after Android studio compilation: error while installing apk
- Solve the error when installing apk after compiling Android Studio: Error while Installing APK
- Error in installing paddlenlp on pip on Windows
- Installing the basemap package in Anaconda
- Installing Theano :Windows Installation Instructions