Skip to content

VPython hangs in Jupyter notebook inside VS Code #281

@ruboerner

Description

@ruboerner

When running VPython inside a Jupyter notebook in VS Code, the code hangs indefinitely.

Minimal working example:

from vpython import *
sphere()

Expected behavior:
A 3D canvas should open and display a sphere.

Actual behavior:
The line with sphere() runs forever without producing output. No error message appears.

Environment:

  • Python version: 3.12.6
  • vpython version: 7.6.5
  • jupyterlab-vpython extension version: 3.1.8
  • OS: MacOS
  • VS Code version: 1.103.2

Additional info:

  • The same code works correctly when run as a standalone Python script in VS Code.
  • The same code works in Jupyterlab outside of VS Code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions