Skip to content

Commit 91cf1b9

Browse files
vidurv-nvidiamyurasov-nv
authored andcommitted
Guard against None PhysicsManager._cfg in _apply_sdf_config
The cloner calls _apply_sdf_config unconditionally on each prototype. If PhysicsManager._cfg is None at that point, cfg.sdf_cfg would raise AttributeError. Add an early return when cfg is None, matching the guard already used in the cloner's pattern compilation code.
1 parent a0ac249 commit 91cf1b9

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

source/isaaclab_newton/isaaclab_newton/physics/newton_manager.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -481,6 +481,8 @@ def _apply_sdf_config(cls, builder: ModelBuilder):
481481
from newton import GeoType, ShapeFlags
482482

483483
cfg = PhysicsManager._cfg
484+
if cfg is None:
485+
return
484486
sdf_cfg = cfg.sdf_cfg
485487
if sdf_cfg is None:
486488
return

0 commit comments

Comments
 (0)