Running code on your computer
A notebook's code runs on your own computer, in the Mac and Windows app, never on Nirvaana's servers.
Nirvaana can set up its own Python for notebooks, use a Python you already have, or run Python inside the app.
Where the code runs
Under a notebook's buttons, “Runs on” says where its code runs, and you can choose another there: Python on this Mac (or this PC) set up by Nirvaana, shown as “Python 3.12 on this Mac” once it's ready; “My own Python”, a Python already on your computer; or “Python in the app (Pyodide)”. Your choice is kept for every notebook.
Setting up Python for notebooks
Until Python is set up, a notebook runs in Python in the app and says “Running in the app for now. Set up Python on this Mac for full speed and every package.” Press “Set up Python on this Mac” (on Windows, “Set up Python on this PC”), and the app asks first. Nothing is installed before your Approve.
Nirvaana sets up its own Python on this Mac, so your notebooks run here, at full speed, with every package.
It installs Python 3.12, with numpy, pandas and matplotlib, and the small tool that installs them (uv), from their own sites.
It takes about 150 MB, all in Nirvaana's own folder. Nothing else on your computer changes.
- While it sets up, cells run in Python in the app, and the notebook says “Running in the app while Python on this Mac is being set up.”
- To use a Python you already have, choose it under “Runs on”. If it needs IPython, the app asks “Get your Python ready for notebooks”: on your Approve it makes a separate place for notebooks (a venv) in Nirvaana's own folder and adds ipykernel there, from PyPI. Your Python itself doesn't change.
Python in the app
Python in the app (Pyodide) needs nothing installed on your computer. The first time, the app fetches its files once and checks each one before it runs. It is slower than Python on your computer, and only pure-Python packages and the ones Pyodide has ready work there.
- It can't use PyTorch, TensorFlow or most database drivers, and it has no GPU, no threads and no way onto the web.
- When something is too heavy, the cell says “This is too heavy for Python in the app. Set up Python on this computer, or Open in VS Code.”
What code can reach
Code runs in the notebook's own folder, and none of the passwords or keys in your computer's settings reach it.
- On a Mac, it can read only its Python, the system's libraries and the notebook's folder, and write only to that folder. It can reach the web, for packages and downloads.
- On Windows, it runs with your own access, so before a notebook's code first runs, the app says “Code in a notebook runs on your computer with your access. Run notebooks only from people you trust.”
- A notebook someone else made asks once before its code runs: “Run code from Ana's notebook?”, with “Not now” and “Approve”.
Stopping, and limits
- “Stop” stops the cell that's running. On Windows, and in Python in the app, Stop starts Python again, and says “Stopped. Variables were cleared.”
- Python on your computer that uses more than 2 GB of memory is started again, and the cell says “This used more than 2 GB of memory, so Python was restarted. Variables were cleared.”
- A cell's output is kept up to 1 MB; past that, a line says so and the rest is left out.
- Python for a notebook ends when you close it, quit the app, or leave it 30 minutes without a run. At most four run at once.
Heavy work: Open in VS Code
“Open in VS Code” writes the notebook to the Nirvaana folder in your home folder (a folder per world) and opens it there, with that editor's own Python. Beside the button, choose VS Code, Cursor, Windsurf or VSCodium; the button then says, for example, “Open in Cursor”.
- The notebook says where the file is, with “Show in Finder” (on Windows, “Show in File Explorer”).
- When you save it in the editor, the notebook asks, for example, “VS Code changed 'Week 3'. Bring the changes back into Nirvaana?”, with “Not now” and “Approve”. If the notebook changed here too, it asks “Both changed. Keep both, or use the editor's?”
- “Always bring changes back from my editor” brings them back without asking.