HNHacker News
TopNewBestAskShowJobs

maitrungduc

4 karma · joined May 12, 2026

Building vivari.run
submissionscomments
maitrungduc··on Numba in the Browser: Unlocking a New Scientific Python Stack in JupyterLite
The persistent caching part is what I would watch most closely, because Numba's on-disk cache has an invalidation rule that this environment can break completely silently.

Functions defined in a notebook cell are fine. The IPython locator stamps the cache with a sha256 of the cell source, so it is content addressed and nothing about the filesystem enters the check.

Functions inside installed packages are the ones to worry about. Those use the file backed locator, whose stamp is (st.st_mtime, st.st_size) of the .py file, and _load_index just returns an empty dict when the stamp does not match. The only trace is a _cache_log line nobody sees unless NUMBA_DEBUG_CACHE is set. So if a later session has its packages unpacked fresh by mamba, every recorded mtime is wrong on arrival, every cached compilation is silently thrown away, and the user simply experiences a slow notebook with cache=True dutifully set.

This is the same problem that led CPython to hash based .pyc in PEP 552, and the reason pip writes them: an installer cannot promise anything about the mtimes of the files it has just written, and a package manager unpacking into a browser filesystem is in exactly that position. The content addressed path already exists in Numba for the IPython case, so the pieces are there.

Worth measuring whether mtimes survive a mamba install into the persistent filesystem across sessions, because that answer decides whether cache=True does anything at all for the PyTensor and PyMC users, who are the ones with compilations expensive enough to care.

maitrungduc··on Show HN: Vivari – Open-Source WebContainer for Node, Bun, and Python
Thank you, really appreciate it.

Good news on that front: Vite and Svelte already work today. The Studio ships templates for Svelte 5 (Vite) and SvelteKit, alongside React, Vue, Astro, Nuxt, Solid, Qwik, Preact and more, and Vite is the default dev server for most of the frontend templates. If you open the Studio you can boot a Svelte + Vite project right now.

The Sandpack comparison is fair, though the approach differs a bit. Sandpack's classic setup bundles in the browser, whereas Vivari runs a real Node (plus Bun and Python) runtime with a virtual filesystem and a process model, so the actual npm dev server runs in-VM instead of a bundler standing in for it. Closer in spirit to WebContainer or CodeSandbox's Nodebox.

On the roadmap: near term I'm focused on hardening what's already there (Next.js and Postgres via PGlite are still experimental), expanding Bun coverage beyond the current shim, and improving the debugger and git support. I'll put up a proper public roadmap soon. If there's a specific framework or workflow you'd want, I'd genuinely like to hear it.