[英]Incompatibility (conflicts) in installing pygeocoder
我無法安裝pygeocoder
。 我該如何解決這個沖突? 我試過pip install
和conda install
。 理論上好像安裝了,但是Jupyter notebook找不到。
使用conda install -c daviskirk pygeocoder
,我看到以下消息:
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: |
Found conflicts! Looking for incompatible packages.
This can take several minutes. Press CTRL-C to abort.
Examining wincertstore: 6%|███████▎ | 2/35 [00:00<00:00, 127.99it/s]
Examining setuptools: 11%|██████████████▉ | 4/35 [00:00<00:01, 23.63it/s]
Examining certifi: 43%|█████████████████████████████████████████████████████████ | 15/35 [00:00<00:00, 23.63it/| -
Comparing specs that have this dependency: 0%| | 0/2 [00:00<?, ?it/s]\
failed /
-
UnsatisfiableError: The following specifications were found
to be incompatible with the existing python installation in your environment:
Specifications:
- pygeocoder -> python=3.5
- pygeocoder -> python[version='>=3.5,<3.6.0a0']
Your python: conda-forge/win-64::python==3.6.7=he025d50_1005
If python is on the left-most side of the chain, that's the version you've asked for.
When python appears to the right, that indicates that the thing on the left is somehow
not available for the python version you are constrained to. Note that conda will not
change your python version to a different minor version unless you explicitly specify
that.
The following specifications were found to be incompatible with each other:
Package wheel conflicts for:
pygeocoder -> python=3.5 -> pip -> wheel
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip -> wheel
Package requests conflicts for:
pygeocoder -> requests[version='>=1.0']
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip -> requests
pygeocoder -> python=3.5 -> pip -> requests
Package ca-certificates conflicts for:
pygeocoder -> requests[version='>=1.0'] -> urllib3[version='>=1.21.1,<1.24'] -> cryptography[version='>=1.3.4'] -> openssl=1.0 -> ca-certificates
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip -> requests -> urllib3[version='>=1.21.1,<1.24'] -> cryptography[version='>=1.3.4'] -> openssl=1.0 -> ca-certificates
Package pip conflicts for:
pygeocoder -> python=3.5 -> pip
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip
Package certifi conflicts for:
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip -> setuptools -> certifi[version='>=2016.09|>=2016.9.26|>=2017.4.17']
pygeocoder -> requests[version='>=1.0'] -> certifi[version='>=2017.4.17']
pygeocoder -> python=3.5 -> pip -> setuptools -> certifi[version='>=2016.09']
pygeocoder -> requests[version='>=1.0'] -> urllib3[version='>=1.21.1,<1.24'] -> certifi
Package msgpack-python conflicts for:
pygeocoder -> python=3.5 -> pip -> cachecontrol -> msgpack-python
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip -> cachecontrol -> msgpack-python
Package setuptools conflicts for:
pygeocoder -> python=3.5 -> pip -> setuptools
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip -> setuptools
Package wincertstore conflicts for:
pygeocoder -> python=3.5 -> pip -> setuptools -> wincertstore[version='>=0.2']
conda-forge/win-64::python==3.6.7=he025d50_1005 -> pip -> setuptools -> wincertstore[version='>=0.2']
該錯誤表明pygeocoder
僅適用於 Python 3.5:
- pygeocoder -> python=3.5 - pygeocoder -> python[version='>=3.5,<3.6.0a0'] Your python: conda-forge/win-64::python==3.6.7=he025d50_1005 ```
對此的最佳實踐解決方案是創建一個新的 env,而不是安裝在基礎Anaconda env 中。 我建議使用 YAML 文件執行此操作,並從一開始就包含您期望需要的所有內容,而不是添加包ad hoc 。
pygeocoder_env.yml
name: pygeocoder_env
channels:
- conda-forge
- daviskirk
- defaults
dependencies:
- python=3.5
- pygeocoder
- ipykernel # needed to use this env as a Jupyter kernel
要創建此環境:
conda env create -f pygeocoder_env.yml
請注意,您仍然應該從基礎環境中啟動 Jupyter,但是當您創建新筆記本時,您可以選擇將此新環境用作內核:
conda activate base
jupyter notebook
如果 env 沒有顯示為內核選項,那么您可能需要安裝nb_conda_kernels
:
conda install -n base nb_conda_kernels
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.