요구 사항을 충족하는 버전을 찾을 수 없습니다.
.04 Python을 12에 여러 requirements.txt 삭제:
numpy>=1.8.2,<2.0.0
matplotlib>=1.3.1,<2.0.0
scipy>=0.14.0,<1.0.0
astroML>=0.2,<1.0
scikit-learn>=0.14.1,<1.0.0
rpy2>=2.4.3,<3.0.0
및 다음 2개의 명령어가 있습니다.
$ pip install --download=/tmp -r requirements.txt
$ pip install --user --no-index --find-links=/tmp -r requirements.txt
(첫 번째는 패키지를 다운로드하고 두 번째는 패키지를 설치합니다).
프로세스가 자주 중지되고 다음 오류가 발생합니다.
Could not find a version that satisfies the requirement <package> (from matplotlib<2.0.0,>=1.3.1->-r requirements.txt (line 2)) (from versions: )
No matching distribution found for <package> (from matplotlib<2.0.0,>=1.3.1->-r requirements.txt (line 2))
수동으로 수정하는 방법:
pip install --user <package>
해 보세요.pip install츠키다
하지만 그것은 그 특정 패키지에만 해당됩니다.두 번째 실행 시pip install다시 명령어를 실행하면 프로세스가 정지되어 다른 필수 패키지에 대해 불만을 표시하며 프로세스를 다시 반복해야 합니다.즉, (위의 명령어를 사용하여) 새로운 필수 패키지를 수동으로 설치한 후 두 번째 패키지를 실행해야 합니다.pip install명령어를 입력합니다.
six,pytz,nose하다', '필요하다', '필요하다', '필요하다', '필요하다', '필요하다', '필요하다' 말하고 있어요mock.
어떻게 말할 수 있을까요?pip필요한 의존관계를 하나씩 수동으로 설치할 필요가 없습니다.
추가: 이 문제는 Ubuntu 12.04 BTW에서만 발생합니다.Ubuntu 14.04에서는pip install 적용되는 requirements.txt파일 작업을 문제없이 수행할 수 있습니다.
이 질문에 대한 해답은 없지만요.이 오류와 함께 동일한 오류 메시지가 표시되는 사용자도 있습니다.
을 위해 첫 글자를 .-r : ★★★pip install -r requirements.txt-r을 사용하다
원래 답은 다음과 같습니다.
https://stackoverflow.com/a/42876654/10093070
python3를 설치했지만 /usr/bin/python의 python은 이전 2.7 버전입니다.
은 효과가 있었다<pkg>pyserial : in in경 :경) : ) 。
python3 -m pip install <pkg>
이 접근법(디렉토리에 모든 종속성이 있고 인덱스에서 다운로드하지 않음)은 디렉토리에 모든 패키지가 포함되어 있는 경우에만 작동합니다.에는 모든 되어 있을 만 아니라되어 있어야 합니다(를 들어, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」, 「」 등).six,pytz 。
이러한 시켜야 합니다.requirements.txt 번째 으로 다운로드 할 수 ) 하여 모든 한 후 PyPI를 사용하여 설치해야 .pip freeze > requirements.txt이치노
누가 이 오류를 검색해서 여기로 오는지 알려드립니다.
다음과 같은 에러가 발생했다고 합니다.
$ python3 example.py
Traceback (most recent call last):
File "example.py", line 7, in <module>
import aalib
ModuleNotFoundError: No module named 'aalib'
「 」라고 되어 있기 aalib , 나는 되었습니다 , 는는 , , , , , , 。aalib:
$ python3.8 -m pip install aalib
ERROR: Could not find a version that satisfies the requirement aalib (from versions: none)
ERROR: No matching distribution found for aalib
하지만 실제로는 패키지 이름이 틀렸습니다.pip search(작성 시 서비스가 비활성화됨) 또는 Google 또는 pypi 사이트에서 검색하여 정확한 패키지 이름을 얻습니다.
인스톨에 성공합니다.
$ python3.8 -m pip install python-aalib
Collecting python-aalib
Downloading python-aalib-0.3.2.tar.gz (14 kB)
...
~로pip --help★★★★
$ python3.8 -m pip --help
...
-v, --verbose Give more output. Option is additive, and can be used up to 3 times.
하지 않고 을 알아내는 , 운에 의존하지 말고 '근원인을 방법'을 수 .-vvv " " " "pip명령어를 사용하여 자세한 내용을 확인할 수 있습니다.§:
$ python3.8 -u -m pip install aalib -vvv
User install by explicit request
Created temporary directory: /tmp/pip-ephem-wheel-cache-b3ghm9eb
Created temporary directory: /tmp/pip-req-tracker-ygwnj94r
Initialized build tracking at /tmp/pip-req-tracker-ygwnj94r
Created build tracker: /tmp/pip-req-tracker-ygwnj94r
Entered build tracker: /tmp/pip-req-tracker-ygwnj94r
Created temporary directory: /tmp/pip-install-jfurrdbb
1 location(s) to search for versions of aalib:
* https://pypi.org/simple/aalib/
Fetching project page and analyzing links: https://pypi.org/simple/aalib/
Getting page https://pypi.org/simple/aalib/
Found index url https://pypi.org/simple
Getting credentials from keyring for https://pypi.org/simple
Getting credentials from keyring for pypi.org
Looking up "https://pypi.org/simple/aalib/" in the cache
Request header has "max_age" as 0, cache bypassed
Starting new HTTPS connection (1): pypi.org:443
https://pypi.org:443 "GET /simple/aalib/ HTTP/1.1" 404 13
[hole] Status code 404 not in (200, 203, 300, 301)
Could not fetch URL https://pypi.org/simple/aalib/: 404 Client Error: Not Found for url: https://pypi.org/simple/aalib/ - skipping
Given no hashes to check 0 links for project 'aalib': discarding no candidates
ERROR: Could not find a version that satisfies the requirement aalib (from versions: none)
Cleaning up...
Removed build tracker: '/tmp/pip-req-tracker-ygwnj94r'
ERROR: No matching distribution found for aalib
Exception information:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/pip/_internal/cli/base_command.py", line 186, in _main
status = self.run(options, args)
File "/usr/lib/python3/dist-packages/pip/_internal/commands/install.py", line 357, in run
resolver.resolve(requirement_set)
File "/usr/lib/python3/dist-packages/pip/_internal/legacy_resolve.py", line 177, in resolve
discovered_reqs.extend(self._resolve_one(requirement_set, req))
File "/usr/lib/python3/dist-packages/pip/_internal/legacy_resolve.py", line 333, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/usr/lib/python3/dist-packages/pip/_internal/legacy_resolve.py", line 281, in _get_abstract_dist_for
req.populate_link(self.finder, upgrade_allowed, require_hashes)
File "/usr/lib/python3/dist-packages/pip/_internal/req/req_install.py", line 249, in populate_link
self.link = finder.find_requirement(self, upgrade)
File "/usr/lib/python3/dist-packages/pip/_internal/index/package_finder.py", line 926, in find_requirement
raise DistributionNotFound(
pip._internal.exceptions.DistributionNotFound: No matching distribution found for aalib
로그를 URL이 합니다.https://pypi.org/simple/aalib/찾을 수 없습니다.404를 찾을 수 없습니다.그러면 잘못된 패키지 이름 등 404의 원인이 될 수 있는 이유를 추측할 수 있습니다.또 하나는 pip 모듈의 관련 python 파일을 수정하여 위의 로그로 디버깅할 수 있습니다..whl명령어를 사용하여및 을 참조할 수 있습니다.
2시간 동안 검색한 끝에 명령어 한 줄만으로 고칠 수 있는 방법을 찾았습니다.패키지의 버전을 알아야 합니다(PARGE 버전을 검색하기만 하면 됩니다).
명령어:
python3 -m pip install --pre --upgrade PACKAGE==VERSION.VERSION.VERSION
아래 명령은 나에게 효과가 있었다 -
python -m pip install flask
항상은 아니지만 패키지가 이미 존재하는 경우도 있습니다.예: getpass."pip list"에는 표시되지 않지만 Import하여 사용할 수 있습니다.
install getpass를 pip하려고 하면 "요건을 충족하는 버전을 찾을 수 없습니다"라는 오류가 나타납니다.
다음 명령을 사용하여 전원 셸에 플라스크를 설치해 보십시오.
pip install --isolated Flask
이것에 의해, 환경 변수나 유저의 설정을 회피할 수 있게 됩니다.
만약 당신이 직장에서 이 문제에 직면한다면.이것이 당신에게 해결책이 될 수도 있습니다.
pip install -U <package_name> --user --proxy=<your proxy>
pypi.org 에서 pip install을 실행합니다.
pip install -U -i https://pypi.org/simple package
초보자들도 오랫동안 고민할 수 있는 성가신 문제이기 때문에, 여기에 완전한 길드를 씁니다.
를 실행하고 있는
pip install PACKAGE★★★★★★★★★★★★★★★★★」python -m pip install PACKAGE및 , , 및no matching version found에러가 보고되었습니다.이 문제를 해결하는 방법은 다음과 같습니다.
브라우저에서 패키지를 검색합니다. 를를 、 。
pycypto해 보겠습니다.pycypto pypi패키지를 찾아서 pypi에서 링크를 열고 파일 다운로드를 클릭합니다.
python 쉘을 열고 설치된 패키지를 Import합니다.예를 들어 Peope를 설치한 적이 있습니다.
>>> import PIL
>>> PIL.__path__
['/Applications/MAMP/htdocs/canvas/src/zzd/env/lib/python3.7/site-packages/PIL']
PACKAGE.__path__은 " "를 합니다.side packages모든 패키지가 들어가는 경로입니다.
PLUS:을 실행합니다.pip list설치된 패키지 목록을 가져옵니다.
- 경로를 얻은 후 셸을 열고 cd를 경로로 이동합니다.
cd /Applications/MAMP/htdocs/canvas/src/zzd/env/lib/python3.7/site-packages/
open
파일의 을 풀고
site-packages.하고, 「cd」를 실행합니다.
setup.py
cd pycrypto-2.6.1
python setup.py install
그러면 패키지를 python으로 Import하여 사용할 수 있습니다.
awscliWindows 10 의 아나콘다(Python 3.7)의 경우.트러블 슈팅중에, https://stackoverflow.com/a/49991357/6862405 에 액세스 해, 다음에 https://stackoverflow.com/a/54582701/6862405 에 액세스 했습니다.라이브러리를 인스톨 할 필요가 있는 것을 알았습니다.PyOpenSSL,cryptography,enum34,idna ★★★★★★★★★★★★★★★★★」ipaddress 후 ( 사용)pip install를 인스톨 할 수 .awscli.
pip 패키지에는 사용하지 않는 python interpreter가 필요합니다.
같은 문제가 발생했는데, Docker 이미지(또는 Docker 파일)에서 명령을 실행했을 때만 발생하였습니다.마침내 몇 시간 후에 나는 내 python interpreter를 업데이트함으로써 그것을 해결할 수 있었다.pip은 python>=3,7이 필요하지만 도커 이미지는 python3.6을 사용하고 있다고 지적했습니다.
힌트: 유사한 문제가 있는지 확인하려면 pip 패키지의 요건과 python 버전을 확인하세요.private pip package inter 요건은 setup.py 또는 setup.cfg에 기재되어 있습니다.퍼블릭 pip 패키지는 보통 pypi.org에서 호스트 됩니다.여기서 브라우저로 인트레터의 요건을 확인할 수 있습니다.python interpreter 버전을 확인하려면 콘솔에 python --version 또는 python3 --version을 입력하십시오.
일반적인 문제 설명
다른 답변에서도 알 수 있듯이, 고객이 만족하지 못하는 다른 요건이 있을 수 있습니다.그 때문에, pip는 적절한 패키지 버전을 찾을 수 없습니다.모든 요건은 pip 패키지 매뉴얼에 기재되어 있어 https://pypi.org/project/graphene-django/your-package에서 쉽게 읽을 수 있습니다.
인터넷 연결이 끊겼을 때 이 오류가 발생했습니다.
MacOS에서는 약간 다른 상황에서 동일한 오류가 발생합니다. 45보다 에서는 몇 가지 할 수 이 명령어를 되지 않습니다.45 다 、 uu 、 보보 、 보 apparent 、 에에 、 got got apparent apparent apparent 。pip3 install setuptools==45
패키지가 로컬인 경우 상대 경로를 놓치지 마십시오.
pip install ./<pkg>
결국 내 경우엔 먹혔어쨌든든
pip install <pkg>
결과:
ERROR: Could not find a version that satisfies the requirement <pkg> (from versions: none)
ERROR: No matching distribution found for <pkg>
pandas-1.4.3비단뱀 pandas-1.4.3 버전 "python"3.8.13와 함께 동작하지 않았습니다.3.8.9:
python install -r requirements.txt # or pip install pandas==1.4.3
# -> Could not find a version that satisfies...
conda activate my_project # creates a virtual env for a new python version
conda install python=3.8.13 # installing the new python version
python --version # displays 3.8.13
pip install -r python/requirements.txt
# -> pandas installed as expected
사용 가능한 패키지의 다른 버전을 찾으면 구글에서 검색하십시오. 예를 들어 glob을 사용하는 동안 오류가 발생하여 glob2를 대신 사용했습니다.
언급URL : https://stackoverflow.com/questions/32302379/could-not-find-a-version-that-satisfies-the-requirement-package
'programing' 카테고리의 다른 글
| "인스턴스에 속성 또는 메서드가 정의되어 있지 않지만 렌더링 중에 참조됩니다." (0) | 2022.11.24 |
|---|---|
| JDBC 배치 삽입 성능 (0) | 2022.11.24 |
| & & in void *p = &&는 무엇을 의미합니까? (0) | 2022.11.24 |
| JS 어레이에서 중복된 값 제거 (0) | 2022.11.24 |
| Vuex 스토어는 Nuxt 어디에 있습니까? (0) | 2022.11.24 |

