Skip to content

Runtime-installable toolboxes#276

Merged
milanofthe merged 44 commits intomainfrom
feature/runtime-toolboxes
May 3, 2026
Merged

Runtime-installable toolboxes#276
milanofthe merged 44 commits intomainfrom
feature/runtime-toolboxes

Conversation

@milanofthe
Copy link
Copy Markdown
Member

@milanofthe milanofthe commented May 3, 2026

Adds support for installing pathsim toolboxes at runtime via a Toolbox Manager, with state persisted across reloads. Built-in pathsim stays bundled; everything else (starting with pathsim-chem) is now a runtime install.

What this PR includes

  • Toolbox Manager modal opened from the Blocks panel header: lists installed toolboxes, lets you add new ones, edit selections, or uninstall.
  • Install sources: curated catalog, PyPI package, wheel URL, single-file .py upload. Each path goes through a trust-warning step before code runs.
  • Backend dispatch: micropip in Pyodide, subprocess pip in the Flask backend (uses the local Python env, skips install when the module is already importable).
  • Per-block overrides during install: display name, category, shape (sourced from the shape registry), and a syncPorts toggle.
  • Persistence in localStorage plus an app-start bootstrap that re-installs and re-registers saved toolboxes.
  • Single source of truth for block/event introspection at scripts/pathview_introspect.py, used by both scripts/extract.py (build time) and src/lib/toolbox/python.ts (runtime, inlined via Vite ?raw). Aligned type names, default formatting, RST docstring HTML, and per-param descriptions.
  • pvm files now embed the toolboxes their blocks come from; loading a file with missing toolboxes prompts to install them. Files saved before this field exists keep loading as before.
  • Unknown block types render as warning-colored placeholders with a dashed outline and (missing) label.
  • Global custom checkbox styling in app.css and NodeCategory opened up to allow runtime-introduced categories.

milanofthe added 30 commits May 3, 2026 17:09
…ts in footer; show built-in toolboxes in manager
milanofthe added 14 commits May 3, 2026 21:31
…T docstring HTML, per-param descriptions, aligned type names and default format
…am type fallback; read docstrings from registry not bundle
…opagate uninstall errors, log event introspection failures
@milanofthe milanofthe merged commit 8879551 into main May 3, 2026
4 checks passed
@milanofthe milanofthe deleted the feature/runtime-toolboxes branch May 3, 2026 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant