2014-01-18 25 views
2

我在Windows上安裝的Python 2.7.6的setuptools 7 64位機,並得到以下錯誤異常有關python setuptools的安裝已在2.7.6

C:\Python27\install_scripts>python ez_setup.py 
Extracting in c:\users\p\appdata\local\temp\tmpqhpyyh 
Now working in c:\users\p\appdata\local\temp\tmpqhpyyh\setuptools-2.1 
Installing Setuptools 
Traceback (most recent call last): 
    File "setup.py", line 17, in <module> 
    exec(init_file.read(), command_ns) 
    File "<string>", line 8, in <module> 
    File "c:\users\p\appdata\local\temp\tmpqhpyyh\setuptools-2.1\setuptools\__init__.py", line 11, in <module> 
    from setuptools.extension import Extension 
    File "c:\users\p\appdata\local\temp\tmpqhpyyh\setuptools-2.1\setuptools\extension.py", line 5, in <module> 
    from setuptools.dist import _get_unpatched 
    File "c:\users\p\appdata\local\temp\tmpqhpyyh\setuptools-2.1\setuptools\dist.py", line 15, in <module> 
    from setuptools.compat import numeric_types, basestring 
    File "c:\users\p\appdata\local\temp\tmpqhpyyh\setuptools-2.1\setuptools\compat.py", line 19, in <module> 
    from SimpleHTTPServer import SimpleHTTPRequestHandler 
    File "C:\Python27\lib\SimpleHTTPServer.py", line 27, in <module> 
    class SimpleHTTPRequestHandler(BaseHTTPServer.BaseHTTPRequestHandler): 
    File "C:\Python27\lib\SimpleHTTPServer.py", line 208, in SimpleHTTPRequestHandler 
    mimetypes.init() # try to read system mime.types 
    File "C:\Python27\lib\mimetypes.py", line 358, in init 
    db.read_windows_registry() 
    File "C:\Python27\lib\mimetypes.py", line 258, in read_windows_registry 
    for subkeyname in enum_types(hkcr): 
    File "C:\Python27\lib\mimetypes.py", line 249, in enum_types 
    ctype = ctype.encode(default_encoding) # omit in 3.x! 
UnicodeDecodeError: 'ascii' codec can't decode byte 0xf4 in position 1: ordinal not in range(128) 
Something went wrong during the installation. 
See the error message above. 

我該如何解決這個問題?在我爲Python 3.4 beta安裝setuptools之前,它已經安裝好了。

回答

2

這是由於一些內部的Python 2.7.6問題而發生的問題。嘗試安裝2.7.5 - 它應該很好。 That's關於python bug跟蹤器的問題的bug報告。

相關問題