2017-12-07 2 views
0

필자는 Portable Python 2.7.6.1을 사용하고 있으며, 매뉴얼을 작성하기 위해 Sphinx 1.5.1을 설치했습니다. 지난 달 스핑크스가 이미 많은 진전을 이뤘으므로 최신 버전 인 Sphinx 1.6.5로 업데이트하려고했지만 easy_install 도구를 사용하여 업그레이드 할 수 없었습니다.easy_install으로 Python Sphinx를 업그레이드하십시오.

easy_install-2.7.exe -U sphinx 

을 그리고는 말한다 :

나는 시도 내가 버전을 강제하려고했던 그 후

Searching for sphinx 
Reading http://pypi.python.org/simple/sphinx/ 
Couldn't retrieve index page for 'sphinx' 
Scanning index of all packages (this may take a while) 
Reading http://pypi.python.org/simple/ 
Best match: sphinx 1.5.1 
Processing sphinx-1.5.1-py2.7.egg 
sphinx 1.5.1 is already the active version in easy-install.pth 

하지만,이 또한 실패

easy_install-2.7.exe -m 1.6.5 sphinx 

이 무엇을이다 라고 :

Searching for 1.6.5 
Reading http://pypi.python.org/simple/1.6.5/ 
Couldn't find index page for '1.6.5' (maybe misspelled?) 
Scanning index of all packages (this may take a while) 
Reading http://pypi.python.org/simple/ 
No local packages or download links found for 1.6.5 
Best match: None 
Traceback (most recent call last): 
    File "C:\Data\Frank\Programme\Portable Python 2.7.6.1\App\Scripts\easy_install-2.7-script.py", line 8, in <module> 
    load_entry_point('setuptools==0.6c11', 'console_scripts', 'easy_install-2.7')() 
    File "C:\Data\Frank\Programme\Portable Python 2.7.6.1\App\lib\site-packages\setuptools\command\easy_install.py", line 1712, in main 
    with_ei_usage(lambda: 
    File "C:\Data\Frank\Programme\Portable Python 2.7.6.1\App\lib\site-packages\setuptools\command\easy_install.py", line 1700, in with_ei_usage 
    return f() 

내가 여기서 뭐하고있는거야? 어쩌면 스핑크스를 제거하는 것이 도움이되지만, 겉으로보기에는 명령 스위치가 easy-install에 있습니다.

답변

1

easy_install의 문서는 간단합니다. upgrading a package을 참조하십시오.

당신은 패키지를 업그레이드하기 위해 특별한 작업을 수행 할 필요가 없습니다 : 그냥 중 특정 버전을 요청하여 새 버전을 설치, 예를 들면 :

easy_install "SomePackage==2.0" 

그래서이 그것을 수행해야합니다

easy_install "Sphinx==1.6.5" 

easy_install과 함께 uninstalling packages도 참조하십시오. 당신이 패키지 (또는 패키지의 모든 버전)의 현재 설치된 버전을 삭제하려면

먼저 실행해야합니다

easy_install -m PackageName 

이 파이썬이 검색을 계속하지 않도록합니다 제거하려는 패키지에 대해 이 작업을 완료 한 후에는 제거하려는 스크립트와 함께 .egg 파일이나 디렉터리를 안전하게 삭제할 수 있습니다.

+0

안녕하세요, 빠른 답장을 보내 주셔서 감사합니다. 게시 된 솔루션은 여전히 ​​나를 위해 작동하지 않습니다. Portable Python이 더 이상 적극적으로 관리되지 않는다는 것을 알아 냈습니다. 아마 이것은 내 문제의 일부가 될 수 있습니다. 나는 지금 파이썬 (x, y)을 대용으로 사용하려고하고있다. – Aleph0

+0

그럴 가능성이 있습니다. 파이썬을 설치한다면 가능하면 최신 3.x 버전을 사용하십시오. 또한 파이썬 패키지 관리를 위해'pip'를 사용하십시오. [Python Packaging Authority (PyPA)에는 튜토리얼과 권장 도구가 있습니다.] (https://packaging.python.org/). –

관련 문제