You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
global, project or no magic env. -> kernel either won't start or crashes for no reason
Steps to reproduce
install magic as intro suggests
create any project
create a .ipynb file
if using vscode select the Mojo (max) kernel
or
run magic run jupyter lab from magic shell env (for conda base env active/inactive before entering magic shell results may vary)
cases observed:
VSCode
kernel just won't start with logs pointing at ~/.modular/pkg/packages.modular.com_max/venv/bin/python not existing but it does.
jupyter lab via: magic shel -> magic run jupyter lab
if conda base env was active only "Mojo (max)" kernel is shown and it fails to start similar to vscode
if no conda env was active "Mojo (max)" and "MAX (Conda ENV Mojo kernel)" are shown but both die with log errors
[I 2025-01-16 00:37:15.788 ServerApp] AsyncIOLoopKernelRestarter: restarting kernel (5/5), new random ports
Traceback (most recent call last):
File "/Users/user1/Library/Jupyter/kernels/mojo-max-jupyter-kernel/mojokernel.py", line 26, in <module>
from ipykernel.kernelapp import IPKernelApp
ModuleNotFoundError: No module named 'ipykernel'
and
[I 2025-01-16 00:38:41.303 ServerApp] AsyncIOLoopKernelRestarter: restarting kernel (5/5), new random ports
Traceback (most recent call last):
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/share/jupyter/kernels/mojo/mojokernel.py", line 390, in <module>
IPKernelApp.launch_instance(
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/lib/python3.12/site-packages/traitlets/config/application.py", line 1074, in launch_instance
app.initialize(argv)
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/lib/python3.12/site-packages/traitlets/config/application.py", line 118, in inner
return method(app, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 707, in initialize
self.init_kernel()
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/lib/python3.12/site-packages/ipykernel/kernelapp.py", line 555, in init_kernel
kernel = kernel_factory(
^^^^^^^^^^^^^^^
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/lib/python3.12/site-packages/traitlets/config/configurable.py", line 583, in instance
inst = cls(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/share/jupyter/kernels/mojo/mojokernel.py", line 190, in __init__
self.lib_mojo_jupyter: ctypes.CDLL = self.load_mojo_lib()
^^^^^^^^^^^^^^^^^^^^
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/share/jupyter/kernels/mojo/mojokernel.py", line 243, in load_mojo_lib
config.get(config_section, "repl_entry_point").rstrip(";")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/lib/python3.12/configparser.py", line 759, in get
d = self._unify_values(section, vars)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/user1/Developer/Code/OtherProjects/poking_around/mojo_src/.magic/envs/default/lib/python3.12/configparser.py", line 1132, in _unify_values
raise NoSectionError(section) from None
configparser.NoSectionError: No section: 'mojo-max-nightly'
respectively
System information
- macOS on apple silicon (in my case 15.1.1 on M1 Pro MacBook Pro)
- conda (mini conda) for python envs management
- magic installed from scratch (latest stable version)
magic 0.6.2 - (based on pixi 0.40.0)
mojo 24.6.0 (4487cd6e)
The text was updated successfully, but these errors were encountered:
Bug description
Running mojo in Notebooks is impossible
Steps to reproduce
Mojo (max)
kernelor
magic run jupyter lab
from magic shell env (for conda base env active/inactive before entering magic shell results may vary)cases observed:
kernel just won't start with logs pointing at
~/.modular/pkg/packages.modular.com_max/venv/bin/python
not existing but it does.if conda base env was active only "Mojo (max)" kernel is shown and it fails to start similar to vscode
if no conda env was active "Mojo (max)" and "MAX (Conda ENV Mojo kernel)" are shown but both die with log errors
and
respectively
System information
The text was updated successfully, but these errors were encountered: