How to keep a standalone script running after calling SimulationApp.close()

Hello, I am writing standalone scripts using pytest. Between each test function fixture I want to close simulation app and relaunch to clean things up. However, when executed using python.sh, upon calling SimulationApp.close() python session quits immediately and tests cannot complete. Is there some way to keep the python session running after calling SimulationApp.close()?

Isaac Sim Version

4.5.0
4.2.0
4.1.0
4.0.0
4.5.0
2023.1.1
2023.1.0-hotfix.1
Other (please specify):

Operating System

Ubuntu 22.04
Ubuntu 20.04
Windows 11
Windows 10
Other (please specify):

GPU Information

  • Model: NVIDIA GeForce RTX 4090
  • Driver Version: 555.42.06

Topic Description

Detailed Description

(Describe the issue in detail, including what you were trying to do, what you expected to happen, and what actually happened)

Steps to Reproduce

  1. In command line window under isaac-sim-4.5.0 directory run ./python.sh
  2. Execute the following python commands
from isaacsim import SimulationApp
app = SimulationApp()
app.close()
  1. python session quits after entering the last line. However I want to keep the session around to execute more python commands

This is a known limitation. The only possible workaround is to use multiprocessing and run the test in a separate process so that calling .close() does not terminate the main process.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.