Unverified Commit d18f0c26 authored by Toni-SM's avatar Toni-SM Committed by GitHub

Fixes Isaac Sim executable on pip installation (#1172)

# Description

This PR fix https://github.com/isaac-sim/IsaacLab/issues/831 by taking
into account the Isaac Sim installation using PIP

- Bug fix (non-breaking change which fixes an issue)

## Checklist

- [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`./isaaclab.sh --format`
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] I have updated the changelog and the corresponding version in the
extension's `config/extension.toml` file
- [x] I have added my name to the `CONTRIBUTORS.md` or my name already
exists there
parent c81550ac
...@@ -81,7 +81,7 @@ if errorlevel 1 ( ...@@ -81,7 +81,7 @@ if errorlevel 1 (
set isaacsim_exe=!isaac_path!\isaac-sim.bat set isaacsim_exe=!isaac_path!\isaac-sim.bat
) else ( ) else (
rem if isaac sim installed from pip rem if isaac sim installed from pip
set isaacsim_exe=isaacsim set isaacsim_exe=isaacsim omni.isaac.sim
) )
rem check if there is a python path available rem check if there is a python path available
if not exist "%isaacsim_exe%" ( if not exist "%isaacsim_exe%" (
......
...@@ -90,9 +90,15 @@ extract_isaacsim_exe() { ...@@ -90,9 +90,15 @@ extract_isaacsim_exe() {
local isaacsim_exe=${isaac_path}/isaac-sim.sh local isaacsim_exe=${isaac_path}/isaac-sim.sh
# check if there is a python path available # check if there is a python path available
if [ ! -f "${isaacsim_exe}" ]; then if [ ! -f "${isaacsim_exe}" ]; then
echo "[ERROR] No Isaac Sim executable found at path: ${isaacsim_exe}" >&2 # check for installation using Isaac Sim pip
if [ $(python -m pip list | grep -c 'isaacsim-rl') -gt 0 ]; then
# Isaac Sim - Python packages entry point
local isaacsim_exe="isaacsim omni.isaac.sim"
else
echo "[ERROR] No Isaac Sim executable found at path: ${isaac_path}" >&2
exit 1 exit 1
fi fi
fi
# return the result # return the result
echo ${isaacsim_exe} echo ${isaacsim_exe}
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment