Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Fixed
^^^^^

* Fixed :class:`~isaaclab_physx.assets.SurfaceGripper` initialization on
non-CPU simulation backends to raise before loading the surface gripper
extension, avoiding hangs during startup.
Original file line number Diff line number Diff line change
Expand Up @@ -443,16 +443,16 @@ def _initialize_impl(self) -> None:
Use `--device cpu` to run the simulation on CPU.
"""

enable_extension("isaacsim.robot.surface_gripper")
from isaacsim.robot.surface_gripper import GripperView

# Check that we are using the CPU backend.
if self._device != "cpu":
raise Exception(
"SurfaceGripper is only supported on CPU for now. Please set the simulation backend to run on CPU. Use"
" `--device cpu` to run the simulation on CPU."
)

enable_extension("isaacsim.robot.surface_gripper")
from isaacsim.robot.surface_gripper import GripperView

# obtain the first prim in the regex expression (all others are assumed to be a copy of this)
template_prim = sim_utils.find_first_matching_prim(self._cfg.prim_path)
if template_prim is None:
Expand Down
10 changes: 10 additions & 0 deletions source/isaaclab_physx/test/assets/test_surface_gripper.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@

"""Launch Isaac Sim Simulator first."""

import os

from isaaclab.app import AppLauncher

# launch omniverse app
Expand All @@ -35,6 +37,10 @@

# from isaacsim.robot.surface_gripper import GripperView

_RUNNING_CI = (
os.environ.get("CI") == "true" or os.environ.get("GITHUB_ACTIONS") == "true" or os.environ.get("GITLAB_CI")
)


def generate_surface_gripper_cfgs(
kinematic_enabled: bool = False,
Expand Down Expand Up @@ -158,6 +164,10 @@ def sim(request):
@pytest.mark.parametrize("device", ["cpu"])
@pytest.mark.parametrize("add_ground_plane", [True])
@pytest.mark.isaacsim_ci
@pytest.mark.skipif(
_RUNNING_CI,
reason="Isaac Sim SurfaceGripperView initialization can deadlock in CI; keep CUDA fail-fast coverage only.",
)
def test_initialization(sim, num_articulations, device, add_ground_plane) -> None:
"""Test initialization for articulation with a surface gripper.

Expand Down
8 changes: 4 additions & 4 deletions tools/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,16 @@ def pytest_ignore_collect(collection_path, config):
on-disk cache is populated.
"""

STARTUP_DEADLINE = 45
STARTUP_DEADLINE = 120
"""Seconds to wait for AppLauncher init or pytest collection before declaring a
startup hang.

AppLauncher prints ``[ISAACLAB] AppLauncher initialization complete`` to
``sys.__stderr__`` (never suppressed) when Kit finishes initializing, and pytest
prints ``collected N items`` to stdout after collection. If neither appears
within this deadline the process is treated as hung. 45 s is above any
legitimate Kit startup (typically 30--60 s) while still catching real hangs
without wasting the full hard timeout.
within this deadline the process is treated as hung. Kit startup can exceed
60 s on cold CI workers, so this catches real startup hangs without killing
legitimate slow launches.
"""

STARTUP_HANG_RETRIES = 2
Expand Down
Loading