Release v0.3.2
PyMOL-RS v0.3.2
A Jupyter integration release — an interactive notebook widget brings the full WASM viewer into Jupyter, while Windows plugin fixes improve cross-platform reliability.
Highlights
Jupyter Notebook Widget
An anywidget-based widget embeds the PyMOL-RS WASM + WebGPU viewer directly in Jupyter notebooks. The widget ships the WASM binary inline (base64-encoded), so it works in JupyterLab, Jupyter Notebook, VS Code, and Google Colab — anywhere anywidget runs.
from pymol_rs.widget import Viewer
view = Viewer()
view.show()
cmd = view.get_cmd()
cmd.fetch("1CRN")
cmd.show("cartoon")
cmd.color("green", "chain A")Features:
- Fire-and-forget commands —
cmd.fetch(),cmd.show(),cmd.color(), etc. via traitlet sync - Synchronous queries — request/response channel for commands that return data
- Local file loading — load structures from the local filesystem into the browser viewer
- Picking support — optional click-to-select atoms (
Viewer(picking=True)) - Configurable layout —
widthandheightparameters with sensible defaults
Bug Fixes
- Windows Python plugin loading — Fixed hardcoded Unix assumptions in the Python plugin:
Scripts/vsbin/for venv paths,;vs:for path list separators (PYTHONPATH,PYTHONHOME), andpython.exelookup order - MSVC delay-load removed — MSVC
/DELAYLOADcannot handle data symbol imports like_Py_NoneStruct(used by PyO3 forPy_None), causing LNK1194 at link time. Removed delay-loading; Python must now be on PATH when the plugin is loaded - Web viewer DSS on fetch — Secondary structure assignment now runs automatically after
fetchin the web viewer, matching native behavior
Under the Hood
- CI caching — Rust dependency caching added to all CI workflows (build, test, release)
- Widget assets in wheels — Release workflow updated to include WASM build artifacts in Python wheel builds
- Clippy clean — Resolved warnings in
web/andpython/crates
Full Changelog: v0.3.1...v0.3.2