Skip to content

Fix lazy physics preset imports#9

Draft
AntoineRichard wants to merge 1 commit into
antoiner/feat/physx-sim-bindingsfrom
antoiner/optional-ovphysx-presets
Draft

Fix lazy physics preset imports#9
AntoineRichard wants to merge 1 commit into
antoiner/feat/physx-sim-bindingsfrom
antoiner/optional-ovphysx-presets

Conversation

@AntoineRichard

@AntoineRichard AntoineRichard commented Apr 28, 2026

Copy link
Copy Markdown
Owner

Summary

  • Added generic lazy preset support for config alternatives backed by import paths.
  • Moved direct task OV-PhysX physics presets to lazy imports so default config loading no longer imports isaaclab_ovphysx.
  • Added regression coverage for lazy preset discovery, selection, and missing-package errors.

Test Plan

  • ./isaaclab.sh -f
  • ./isaaclab.sh -p -m pre_commit run --files source/isaaclab_tasks/isaaclab_tasks/utils/hydra.py source/isaaclab_tasks/test/test_hydra.py source/isaaclab_tasks/isaaclab_tasks/direct/cartpole/cartpole_env_cfg.py source/isaaclab_tasks/isaaclab_tasks/direct/ant/ant_env_cfg.py source/isaaclab_tasks/isaaclab_tasks/direct/humanoid/humanoid_env_cfg.py source/isaaclab_tasks/isaaclab_tasks/direct/locomotion/locomotion_env.py source/isaaclab_tasks/docs/CHANGELOG.rst source/isaaclab_tasks/config/extension.toml source/isaaclab_tasks/isaaclab_tasks/utils/init.pyi
  • PYTHONPYCACHEPREFIX=/tmp/isaaclab_pycache ./isaaclab.sh -p -m py_compile source/isaaclab_tasks/isaaclab_tasks/utils/hydra.py source/isaaclab_tasks/isaaclab_tasks/direct/cartpole/cartpole_env_cfg.py source/isaaclab_tasks/isaaclab_tasks/direct/ant/ant_env_cfg.py source/isaaclab_tasks/isaaclab_tasks/direct/humanoid/humanoid_env_cfg.py source/isaaclab_tasks/isaaclab_tasks/direct/locomotion/locomotion_env.py source/isaaclab_tasks/test/test_hydra.py

Not Run

  • PYTHONPYCACHEPREFIX=/tmp/isaaclab_pycache ./isaaclab.sh -p -m pytest source/isaaclab_tasks/test/test_hydra.py -q: blocked because the /usr/bin/python3.12 environment is missing torch.
  • ./isaaclab.sh -d: blocked by PEP 668 externally-managed system Python while installing docs requirements.

Add a lazy preset helper so config alternatives can defer backend imports until a preset is selected.

Use it for direct task OV-PhysX physics presets and keep locomotion gear selection independent of the optional package import.
@AntoineRichard AntoineRichard force-pushed the antoiner/optional-ovphysx-presets branch from 4c6584f to cf4bfe0 Compare April 28, 2026 08:51
@AntoineRichard AntoineRichard changed the title Fix optional OV-PhysX preset imports Fix lazy physics preset imports Apr 28, 2026
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