M
Modular•2w ago
Pun

Getting jupyter lab to run mojo on Apple Silicon

I'm unable to find the mojo kernal on VSCode Jupyter nor the web version of Jupyter Lab. What could I be missing? The tutorial seems incorrect https://github.com/modularml/mojo/blob/main/examples/notebooks/README.md VSCode seems to explicitly require a python environment. And $MODULAR_HOME is not a thing that exists I also made a pull request towards the docs https://github.com/modularml/mojo/pull/3803 to clear up what I could
GitHub
mojo/examples/notebooks/README.md at main · modularml/mojo
The Mojo Programming Language. Contribute to modularml/mojo development by creating an account on GitHub.
GitHub
[Docs] Update the notebook tutorial by PunkPun · Pull Request #3803...
And add more clarification to end users not familiar with conda .yml files
No description
7 Replies
ModularBot
ModularBot•2w ago
Congrats @Pun, you just advanced to level 1!
dohzya
dohzya•2w ago
I didn't found a way that I like but it is possible: - be sure to be in a magic project (it's working when using magic shell, I suppose it's not mandatory if you find the right variables and the rights values) - be sure to have installed max ipykernel and python in your magic env - call code from your shell (quit it before doing this just to be sure) I'm quite certain there is a way to be more generic, but my testing until now were closer to alchemy than real reproductible science 😬
Pun
PunOP•2w ago
magic init hello-mojo;
cd hello-mojo;
magic add max;
magic init hello-mojo;
cd hello-mojo;
magic add max;
this seems to work, Jupyter extension just detects it. I still seem to be struggling with older projects
Pun
PunOP•2w ago
No description
Pun
PunOP•2w ago
ok even
magic init hello-world --format mojoproject
magic init hello-world --format mojoproject
is enough. Key is to have a mojo .ipynb in the directory, and also launch vscode from magic shell at least once no need to magic install python or ipykernal separately and it still doesn't work reliably!!!!!!!
Pun
PunOP•2w ago
this can also happen when you try to run it
dohzya
dohzya•2w ago
I had this issue once, and fixed it by installing ipykernal 😬 (I think. maybe I didn't other install / config which I don't remember)
Want results from more Discord servers?
Add your server