How to force `conda` to install the latest version of `jupyter`?

余生颓废 提交于 2019-12-11 18:04:16

问题


This question is motivated by `jupyter notebook` gives error: `"Could not open static file ''"` on macOS

After conda update jupyter, jupyter --version gives jupyter-notebook : 6.0.0

However on https://github.com/jupyter/notebook, clicking Branch: master -> tags I see a 6.0.1 tag.

How can I upgrade to 6.0.1?

> conda install jupyter=6.0.1
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.

PackagesNotFoundError: The following packages are not available from current channels:

  - jupyter=6.0.1

Current channels:

  - https://repo.anaconda.com/pkgs/main/osx-64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/r/osx-64
  - https://repo.anaconda.com/pkgs/r/noarch

To search for alternate channels that may provide the conda package you're
looking for, navigate to

    https://anaconda.org

and use the search bar at the top of the page.

I can't see any candidates on https://anaconda.org

Is this a dead-end?


回答1:


First, note that the actual package you want to upgrade/install is notebook, not jupyter. The Anaconda channel hasn't released that version of notebook yet. Conda Forge has it, so you can get it with

conda install -c conda-forge notebook

However, just be aware that compatibility between Conda Forge and Anaconda package builds is not guaranteed. Best practice is to create a new env that prioritizes Conda Forge from the start:

conda create -n my_jupyter_env -c conda-forge jupyter

Generally it isn't a good idea to mess with base env, and if you want something other than a default Anaconda install, I recommend starting with Miniconda and leaving base alone (other than the occasional conda upgrade conda).



来源:https://stackoverflow.com/questions/57843733/how-to-force-conda-to-install-the-latest-version-of-jupyter

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!