You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
VPython hangs in Jupyter notebook inside VS Code #281
The silent hang is fixed in Fail loudly instead of hanging forever when no frontend connects (#281) #292: import vpython now fails after 30s with a clear error naming the environment (VS Code detected via its env vars) and pointing at what works, instead of hanging the kernel forever. VPYTHON_CONNECT_TIMEOUT raises the limit for genuinely slow first-runs.
Actual VS Code support is being designed: a VS Code extension using the Notebook Renderer API + Jupyter kernel comm messaging (the mechanism ipywidgets uses), rendering through the same host-agnostic glowcomm_host.js frontend recently factored out on the pyodide-packaging branch (Pyodide/wasm support: pure-Python wheel, worker transport, GlowScript host factory #291). No timeline promised yet, but the hang at least stops being silent now.
Update: VPython scenes now render live in VS Code notebooks — working prototype, end to end. Objects, rate() animation, zoom/orbit, text() fonts, and textures all verified.
Renderer side: https://github.com/vpython/vscode-vpython — a VS Code notebook renderer extension that loads GlowScript in the output webview and connects to that websocket. Not on the marketplace yet; installable from a packaged vsix.
With the extension absent, import vpython fails loudly per #292 instead of hanging. Remote kernels (WSL/SSH/Codespaces) are the main known gap — needs the extension to ask VS Code for port forwarding.
Activity
sspickle commentedon Aug 16, 2026
Two-part answer to this issue is underway:
The silent hang is fixed in Fail loudly instead of hanging forever when no frontend connects (#281) #292:
import vpythonnow fails after 30s with a clear error naming the environment (VS Code detected via its env vars) and pointing at what works, instead of hanging the kernel forever.VPYTHON_CONNECT_TIMEOUTraises the limit for genuinely slow first-runs.Actual VS Code support is being designed: a VS Code extension using the Notebook Renderer API + Jupyter kernel comm messaging (the mechanism ipywidgets uses), rendering through the same host-agnostic
glowcomm_host.jsfrontend recently factored out on thepyodide-packagingbranch (Pyodide/wasm support: pure-Python wheel, worker transport, GlowScript host factory #291). No timeline promised yet, but the hang at least stops being silent now.🤖 Generated with Claude Code
Merge pull request #292 from vpython/fix/281-frontend-connect-timeout
sspickle commentedon Aug 16, 2026
Update: VPython scenes now render live in VS Code notebooks — working prototype, end to end. Objects,
rate()animation, zoom/orbit,text()fonts, and textures all verified.Two pieces:
With the extension absent,
import vpythonfails loudly per #292 instead of hanging. Remote kernels (WSL/SSH/Codespaces) are the main known gap — needs the extension to ask VS Code for port forwarding.fix: compound/text/extrusion/pause deadlock forever in Colab — raise …