Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing correct ipython kernel in c1w1, conda method #61

Open
B0B44 opened this issue Jun 12, 2022 · 0 comments
Open

Missing correct ipython kernel in c1w1, conda method #61

B0B44 opened this issue Jun 12, 2022 · 0 comments

Comments

@B0B44
Copy link

B0B44 commented Jun 12, 2022

While following instructions after launching the Jupiter lab, I noticed that kernel was missing.
The default kernel named "Python" could not be launched due to an exception regarding distutils.

Traceback from Jupyter lab server log:

[I 2022-06-12 11:22:32.002 ServerApp] AsyncIOLoopKernelRestarter: restarting kernel (5/5), new random ports
Traceback (most recent call last):
  File "/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/bob/.local/lib/python3.6/site-packages/ipykernel_launcher.py", line 15, in <module>
    from ipykernel import kernelapp as app
  File "/home/bob/.local/lib/python3.6/site-packages/ipykernel/__init__.py", line 2, in <module>
    from .connect import *
  File "/home/bob/.local/lib/python3.6/site-packages/ipykernel/connect.py", line 16, in <module>
    import jupyter_client
  File "/home/bob/.local/lib/python3.6/site-packages/jupyter_client/__init__.py", line 6, in <module>
    from .asynchronous import AsyncKernelClient  # noqa
  File "/home/bob/.local/lib/python3.6/site-packages/jupyter_client/asynchronous/__init__.py", line 1, in <module>
    from .client import AsyncKernelClient  # noqa
  File "/home/bob/.local/lib/python3.6/site-packages/jupyter_client/asynchronous/client.py", line 8, in <module>
    from jupyter_client.client import KernelClient
  File "/home/bob/.local/lib/python3.6/site-packages/jupyter_client/client.py", line 20, in <module>
    from .connect import ConnectionFileMixin
  File "/home/bob/.local/lib/python3.6/site-packages/jupyter_client/connect.py", line 27, in <module>
    from jupyter_core.paths import jupyter_data_dir  # type: ignore
  File "/usr/lib/python3/dist-packages/jupyter_core/paths.py", line 21, in <module>
    from distutils.util import strtobool
ModuleNotFoundError: No module named 'distutils.util'

This issue can be avoided by registering the conda environment python runtime with ipython, using the following command

python -m ipykernel install --user --name mlep-w1-lab

I'll create a pull request with an updated readme file if given the green light.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant