[英]How to install packages on portable python
Good morning, 早上好,
i'm trying to install a package on portable python. 我正在尝试在便携式python上安装软件包。 I found that i do not have the easy_install.exe file, I just have the easy_install.py file.
我发现我没有easy_install.exe文件,而我只有easy_install.py文件。
I tried the following from prompt_CDOS: 我尝试从提示符提示符CDOS:
1)
C:\Software\Portable Python 3.2.5.1>app\py
thon.exe textract-1.6.1.tar\textract-1.6.1\setup.py
Traceback (most recent call last):
File "textract-1.6.1.tar\textract-1.6.1\setup.py", line 4, in <module>
from setuptools import setup
File "C:\Software\Portable Python 3.2.5.
1\app\lib\site-packages\setuptools\__init__.py", line 2, in <module>
from setuptools.extension import Extension, Library
File "C:\Software\Portable Python 3.2.5.
1\app\lib\site-packages\setuptools\extension.py", line 5, in <module>
from setuptools.dist import _get_unpatched
File "C:\Software\Portable Python 3.2.5.
1\app\lib\site-packages\setuptools\dist.py", line 103
except ValueError, e:
^
SyntaxError: invalid syntax
2)
C:\Software\Portable Python 3.2.5.1>App\py
thon.exe App\easy_install.py textract-1.6.1.tar\textract-1.6.1\setup.py
Traceback (most recent call last):
File "App\easy_install.py", line 4, in <module>
from setuptools.command.easy_install import main
File "C:\Software\Portable Python 3.2.5.
1\App\lib\site-packages\setuptools\__init__.py", line 2, in <module>
from setuptools.extension import Extension, Library
File "C:\Software\Portable Python 3.2.5.
1\App\lib\site-packages\setuptools\extension.py", line 5, in <module>
from setuptools.dist import _get_unpatched
File "C:\Software\Portable Python 3.2.5.
1\App\lib\site-packages\setuptools\dist.py", line 103
except ValueError, e:
^
SyntaxError: invalid syntax
any suggestion? 有什么建议吗?
thanks 谢谢
The syntax 语法
except ValueError, e:
^
SyntaxError: invalid syntax
is for Python 2. The error is from the file C:\\Software\\Portable Python 3.2.5. 1\\App\\lib\\site-packages\\setuptools\\dist.py
是针对Python 2的。错误来自文件
C:\\Software\\Portable Python 3.2.5. 1\\App\\lib\\site-packages\\setuptools\\dist.py
C:\\Software\\Portable Python 3.2.5. 1\\App\\lib\\site-packages\\setuptools\\dist.py
. C:\\Software\\Portable Python 3.2.5. 1\\App\\lib\\site-packages\\setuptools\\dist.py
It seems you have a wrong version of setuptools
installed. 看来你有一个错误的版本
setuptools
安装。 You have setuptools
for Py2 but you need setuptools
for Py3. 你有
setuptools
对的Py2,但你需要setuptools
的PY 3。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.