我正试图为python3.5(pyodbc,pandas)安装两个包,但是这个过程被卡住了。我试过的第一件事是:C:\Program Files (x86)\Python 3.5\Scripts> pip install pyodbc
这给了我以下信息
^{pr2}$
我再试试C:\Program Files (x86)\Python 3.5\Scripts> pip install pkg_resources
这会产生相同的pkg_资源错误。在
下一步我试试C:\Program Files (x86)\Python 3.5\Scripts> easy_install-3.5 install pkg_resources
以及C:\Program Files (x86)\Python 3.5\Scripts> easy_install-3.5 pkg_resources
两者都能产生Searching for pkg-resources
Reading https://pypi.python.org/simple/pkg_resources/
No local packages or download links found for pkg-resources error: Could not find suitable distribution for Requirement.parse('pkg-resources')
经过进一步搜索,有人认为setuptools可能已过时。目前我有setuptools 16.0,而我看到的最新版本是25.1.6。当我尝试使用pip更新setuptools时C:\Program Files (x86)\Python 3.5\Scripts> pip install -U setuptools
我再次收到pkg_resources错误。如果我使用easy_install-3.5进行更新,它将重新安装16.0版本。在
接下来,我尝试通过下载.whl文件手动安装setuptools。在C:\Program Files (x86)\Python 3.5\Scripts>pip install "C:\Users\xxxx\Downloads\setuptools-25.1.6-py2.py3-none-any.whl"
但这又给了pkg_resources错误。在
因为我的目标是简单地安装软件包,所以我也尝试过C:\Program Files (x86)\Python 3.5\Scripts> easy_install-3.5 install pyodbc
这就产生了同样的没有本地包或下载链接的错误。如果我跑了C:\Program Files (x86)\Python 3.5\Scripts> easy_install-3.5 pyodbc
我明白了C:\Program Files (x86)\Python 3.5\Scripts>easy_install-3.5 pyodbc
Searching for pyodbc
Reading https://pypi.python.org/simple/pyodbc/
Best match: pyodbc 3.0.10
Downloading https://pypi.python.org/packages/9c/6f/27ffd47f56226e572bb8cf06a8355d8ed875b49b8317e73a95c20fb599d1/pyodbc-3.0.10.tar.gz#md5=3f6f205c979a0fe5dee05d37121a7b92
Processing pyodbc-3.0.10.tar.gz
Writing C:\Users\xxxx\AppData\Local\Temp\easy_install-97z1da15\pyodbc-3.0.10\setup.cfg
Running pyodbc-3.0.10\setup.py -q bdist_egg --dist-dir C:\Users\xxxx\AppData\Local\Temp\easy_install-97z1da15\pyodbc-3.0.10\egg-dist-tmp-00jdn31z
error: [WinError 32] The process cannot access the file because it is being used by another process: 'C:\\Users\\xxxxx\\AppData\\Local\\Temp\\easy_install-97z1da15\\pyodbc-3.0.10\\pyodbc.egg-info\\SOURCES.txt'
有什么想法吗?在