Jupyter Lite and Python on the Internet Computer

I’m trying to get Jupyter Lite to run in a canister but I keep getting errors.

Jupyter Lite is based on Pyodide, which is a CPython 3.8 interpreter compiled to WebAssembly, so you can run Python in the browser!

Recent medium article about it: https://blog.jupyter.org/jupyterlite-jupyter-%EF%B8%8F-webassembly-%EF%B8%8F-python-f6e2e41ab3fa

Documentation: https://jupyterlite.readthedocs.io/en/latest/index.html

Here are the static assets running successfully on shared hosting (just on my personal website): https://bobbodily.com/jupyter/. So the static assets are working (although you will see a few acceptable although annoying 404 errors if you look in the console)

And here are the static assets that are NOT working deployed to a canister: https://dm2qx-4aaaa-aaaah-aaecq-cai.raw.ic0.app/

Talking to an IC dev friend he thinks it might be trying to redirect all requests back to index.html if the resource isn’t found, and if we could turn off that redirect it might work. Some evidence for that is when you load the website it doesn’t load, but if you go directly here https://dm2qx-4aaaa-aaaah-aaecq-cai.raw.ic0.app/lab/index.html then it will take a while, but it will eventually load for you. BUT, then if I try to create a notebook, it fails and can’t open it.

1 Like