我有将 python 从 3.5 升级到 3.6 的坏主意。现在我无法重新安装我使用的任何软件包(scipy、numpy、..)。
我使用的命令pip3 install -U numpy
pip3 --version
返回
pip 9.0.1
我有 Visual Studio 2015 社区的许可安装。
我在 Win7 x64 上,我设置为 env varVS100COMNTOOLS=%VS140COMNTOOLS%
我得到的巨大错误的最后 5 行是:
No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools
----------------------------------------
Command "c:\users\admin\appdata\local\programs\python\python36\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\admin\\AppData\\Local\\Temp\\pip-build-65uc3b3g\\numpy\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(c
ode, __file__, 'exec'))" install --record C:\Users\admin\AppData\Local\Temp\pip-huz2nklc-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\admin\AppData\Local\Temp\pip-build-65uc3b3g\numpy\