voila-dashboards / voila

Voilà turns Jupyter notebooks into standalone web applications
https://voila.readthedocs.io
Other
5.46k stars 506 forks source link

Installing voila in an anaconda environment - idna package missing #720

Open enryH opened 4 years ago

enryH commented 4 years ago

Platform: Win10

I installed voila in an anaconda environment without installing jupyterlab along side. I go the same error as described here (I missed to save it...)

(env) voila notebook.ipynb

Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\Scripts\jupyter-notebook-script.py", line 6, in <module>
    from notebook.notebookapp import main
  File "C:\ProgramData\Anaconda3\lib\site-packages\notebook\notebookapp.py", line 80, in <module>
    from .services.contents.manager import ContentsManager
  File "C:\ProgramData\Anaconda3\lib\site-packages\notebook\services\contents\manager.py", line 17, in <module>
    from nbformat import sign, validate as validate_nb, ValidationError
  File "C:\ProgramData\Anaconda3\lib\site-packages\nbformat\__init__.py", line 32, in <module>
    from .validator import validate, ValidationError
  File "C:\ProgramData\Anaconda3\lib\site-packages\nbformat\validator.py", line 12, in <module>
    from jsonschema import ValidationError
  File "C:\ProgramData\Anaconda3\lib\site-packages\jsonschema\__init__.py", line 14, in <module>
    from jsonschema._format import (
  File "C:\ProgramData\Anaconda3\lib\site-packages\jsonschema\_format.py", line 240, in <module>
    @_checks_drafts(draft7="idn-hostname", raises=idna.IDNAError)
AttributeError: module 'idna' has no attribute 'IDNAError'

I had conda install idna manually additionally in the environment to get it to work.

I don't know why it was missing, but I wanted to document it briefly.

maartenbreddels commented 4 years ago

Did you create a new environment? If not, could you create a new environment, this might be an old problem not related to voila that is fixed

enryH commented 4 years ago

No, I try to have my jupyter eco-system in a base environment and link the execution environments using ipykernels only.

PranjalSahu commented 3 years ago

This issue occured to me in Ubuntu when I did conda update --all. After restarting the jupyter notebook kept getting the message AttributeError: module 'idna' has no attribute 'IDNAError'. conda install idna solved the problem for me too.