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
examples: use proper pyproject.toml setup for all python ones #985
Partner feedback on #736 (item 5): the Physical AI Developer team copied example code into their own project, hit import failures, and patched their copies with dual-mode import guards. Worth settling a convention rather than leaving each example to pick one.
Two conventions coexist under examples/:
mujoco_xr — its own wheel, isaacteleop_examples.mujoco_xr namespace, relative imports, documented as python -m. Copies cleanly.
camera_viz and teleop_ros2/python — 21 files import siblings as top-level modules: from pipeline import ..., from sources import ..., from messages import ..., from geometry import .... These resolve only because the script's own directory lands on sys.path.
So the second group breaks under python -m, breaks the moment a file is copied into a package (what the partner hit), and squats on very generic top-level names — pipeline, sources, messages, constants, assets. examples/teleop_ros2/python/pyproject.toml already carries pythonpath = ["."] to keep pytest working around it.
Suggested direction: make both directories real packages with relative imports plus a -m entry point, matching mujoco_xr, and write the convention down for examples. I'd avoid adopting try: from .x / except ImportError: from x guards repo-wide — that doubles every import site to paper over an invocation mistake.
Cross-repo note: huggingface/lerobot's examples/isaac_teleop_to_so101/ uses files(__package__) (common.py:76) and relative imports. Its README documents python -m only, so it works as specified; recording it here for traceability.
changed the title [-]examples: flat sibling imports make camera_viz and teleop_ros2 script-mode-only[/-][+]examples: use proper pyproject.toml setup for all python ones[/+]on Aug 20, 2026
Activity
[-]examples: flat sibling imports make camera_viz and teleop_ros2 script-mode-only[/-][+]examples: use proper pyproject.toml setup for all python ones[/+]examples(deviceio_live_view): package under isaacteleop_examples
examples(teleop_session_manager): package under isaacteleop_examples
examples: write down the Python example convention
examples(retargeting): package under isaacteleop_examples
examples(camera_viz): package under isaacteleop_examples
examples(cloudxr_mujoco_teleop): package under isaacteleop_examples
examples: write down the Python example convention
examples(oxr): package under isaacteleop_examples
examples(teleop): package under isaacteleop_examples
159 remaining items
examples(noitom, oglo_tactile): package under isaaccapture_examples (#…
docs(examples): cover rebuilds of editable examples and Isaac Lab
examples(vehicle_teleop): keep tests off the example index, tidy README
examples(teleop): package under isaaccapture_examples
examples(teleop): fix what the package move left behind
examples(teleop): fix what the package move left behind
docs(examples): add demo extras, venv reuse and drop soma's cmake step
examples(oxr): package under isaaccapture_examples (#1372)
fix(camera_viz): let setup --wheel find the isaacteleop transition wheel
docs(examples): reuse an existing venv, state editable rebuilds once
examples(teleop): name both install paths; fail fast without ui
examples(vehicle_teleop): install the local isaaccapture build the ca…
examples(vehicle_teleop): package under isaaccapture_examples (#1375)
examples(teleop): package under isaaccapture_examples (#1374)
docs(examples): install the local isaaccapture build the canonical way (