2

I created a new environment in Anaconda, and I cannot get Jupyter Notebooks TOC to work. I tried the answers in a similar question at Jupyter Configurable nbextensions list is empty.

I initially created my new env in Anaconda prompt like this:

conda create --name py38 python=3.8
conda config --env --add channels conda-forge
conda config --env --set channel_priority strict
conda install -c conda-forge notebook
ipython kernel install --name "py38" --user
conda install -c conda-forge jupyter_nbextensions_configurator
conda install -c conda-forge jupyter_contrib_nbextensions
jupyter nbextensions_configurator enable --user

Expected Behavior #1 enter image description here


Actual Behavior #1

enter image description here


Expected Behavior #2

enter image description here


Actual Behavior #2

enter image description here


I did notice that when launching jupyter notebook from Anaconda prompt, it kept printing Config option `template_path` not recognized by into the prompt. Notebook launched fine, but the TOC switch wasn't there and the Nbextentions tab looked different than in my other environments. (I tried toggling TOC on/off in the Nbextensions tab.) See the expected/actual behavior screen grabs shown above.

Following this discussion relating to template path on Github, I tried the to create a new environment using the following (in Anaconda prompt), specifically down-grading nbconvert, but the same Actual Behaviors as above remained.

conda create --name test2 python=3.8
conda config --env --add channels conda-forge
conda config --env --set channel_priority strict
conda install -c conda-forge notebook
conda install -c conda-forge nbconvert==5.6.1
ipython kernel install --name "test2" --user
conda install -c conda-forge jupyter_nbextensions_configurator
conda install -c conda-forge jupyter_contrib_nbextensions
jupyter nbextensions_configurator enable --user

How can I get the TOC in my new environment in Jupyter Notebook?

a11
  • 3,122
  • 4
  • 27
  • 66
  • 3
    Check whether you have `nbconvert==5.6.1` as requested. [This thread](https://github.com/ipython-contrib/jupyter_contrib_nbextensions/issues/1529) attributes the `template_path` error to nbconvert 6. Did your subsequent `conda` calls update it on you? – ctwardy Nov 01 '21 at 16:33

0 Answers0