我刚刚注册了DotCloud并在安装pip包时得到了这个。试图摆弄,无法解决它 在python 3.2下运行pip 1.2.1。
抱歉,我不知道Python的内容,所以无法自己弄清楚如何解决这个问题。如果你有任何python帮助给我,请轻轻地做(虽然我很熟悉PHP / Ruby)。
$ sudo easy_install pip && sudo pip install dotcloud
[sudo] password for myself:
Searching for pip
Best match: pip 1.2.1
pip 1.2.1 is already the active version in easy-install.pth
Installing pip script to /usr/local/bin
Installing pip-3.2 script to /usr/local/bin
Using /usr/local/lib/python3.2/dist-packages
Processing dependencies for pip
Finished processing dependencies for pip
Downloading/unpacking dotcloud
Running setup.py egg_info for package dotcloud
Requirement already satisfied (use --upgrade to upgrade): argparse in /usr/local/lib/python3.2/dist-packages (from dotcloud)
Downloading/unpacking requests==0.14.2 (from dotcloud)
Running setup.py egg_info for package requests
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/tmp/pip-build/requests/setup.py", line 6, in <module>
import requests
File "requests/__init__.py", line 52, in <module>
from . import utils
File "requests/utils.py", line 22, in <module>
from .compat import parse_http_list as _parse_list_header
File "requests/compat.py", line 112, in <module>
from .packages import chardet2 as chardet
ImportError: cannot import name chardet2
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/tmp/pip-build/requests/setup.py", line 6, in <module>
import requests
File "requests/__init__.py", line 52, in <module>
from . import utils
File "requests/utils.py", line 22, in <module>
from .compat import parse_http_list as _parse_list_header
File "requests/compat.py", line 112, in <module>
from .packages import chardet2 as chardet
ImportError: cannot import name chardet2
答案 0 :(得分:1)
这可能与请求和python 3.2有关。您可以尝试安装以下软件包,然后重试安装dotCloud CLI吗?
pip install chardet2 urllib3
答案 1 :(得分:0)
看起来,目前DotCloud不支持Python 3,不幸的是Python 3是新机器上Python的默认版本。
因此,看起来无法通过点子安装dotcloud
但是,我设法下载standalone package,解压缩并使用sudo ./setup.py install
进行安装。该脚本自动调用Python 2.7并干净地安装所有内容。