Notebook DuckDB Assets Package
Status: Implemented for the current package boundary.
packages/notebook/duckdb-assetsowns the current browser/PWA DuckDB-Wasm and DuckDB worker asset URL resolver consumed by the notebook product plugin.
Purpose
@lapis-notes/notebook-duckdb-assets separates DuckDB asset ownership from the product plugin’s DuckDB service. The product plugin still owns DuckDB lifecycle, table registration, query execution, catalog inspection, and notebook progress phases, but raw wasm and worker URL imports live behind this resolver package.
Current Scope
- MVP DuckDB-Wasm module URL
- exception-handling DuckDB-Wasm module URL
- MVP DuckDB browser worker URL
- exception-handling DuckDB browser worker URL
getNotebookDuckDbBundles()resolver compatible withduckdb.selectBundle()
Production builds copy DuckDB wasm and worker files to dist/duckdb/ instead
of inlining them into JavaScript bundles. Official notebook releases include
those paths in the signed .lapis-plugin bundle, so first SQL execution
resolves installed plugin asset URLs without making a post-install release
download.
Boundary Rules
This package must stay asset-only. It should not instantiate DuckDB, open connections, register files, query tables, import app APIs, or depend on product-plugin runtime code. Browser/PWA asset resolution can evolve here without changing notebook query behavior.
Consumers
@lapis-notes/notebook consumes this package from NotebookDuckDbService when that service is lazily loaded by DuckDB-backed notebook execution or inspection paths.