Commit 9139ec44 authored by Kelly Guo's avatar Kelly Guo Committed by Kelly Guo

Adds warning for conda install without symlink (#442)

# Description

When using conda with binary installation of Isaac Sim, we require first
creating the symlink _isaac_sim before creating the conda environment so
that we can find the source file to set up the conda environment
correctly. This change adds a warning message if we do not detect
_isaac_sim when the conda environment is created as a way to indicate
potential issues for users.


## Type of change

- This change requires a documentation update

## Checklist

- [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`./isaaclab.sh --format`
- [x] 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
- [ ] I have added my name to the `CONTRIBUTORS.md` or my name already
exists there

<!--
As you go through the checklist above, you can mark something as done by
putting an x character in it

For example,
- [x] I have done this task
- [ ] I have not done this task
-->
parent 28762da0
......@@ -114,6 +114,17 @@ if errorlevel 1 (
echo [ERROR] Conda could not be found. Please install conda and try again.
exit /b 1
)
rem check if _isaac_sim symlink exists and isaacsim-rl is not installed via pip
if not exist "%ISAACLAB_PATH%\_isaac_sim" (
python -m pip list | findstr /C:"isaacsim-rl" >nul
if errorlevel 1 (
echo [WARNING] _isaac_sim symlink not found at %ISAACLAB_PATH%\_isaac_sim
echo This warning can be ignored if you plan to install Isaac Sim via pip.
echo If you are using a binary installation of Isaac Sim, please ensure the symlink is created before setting up the conda environment.
)
)
rem check if the environment exists
call conda env list | findstr /c:"%env_name%" >nul
if %errorlevel% equ 0 (
......
......@@ -22,6 +22,27 @@ export ISAACLAB_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && p
# Helper functions
#==
# install system dependencies
install_system_deps() {
# check if cmake is already installed
if command -v cmake &> /dev/null; then
echo "[INFO] cmake is already installed."
else
# check if running as root
if [ "$EUID" -ne 0 ]; then
echo "[INFO] Installing system dependencies..."
sudo apt-get update && sudo apt-get install -y --no-install-recommends \
cmake \
build-essential
else
echo "[INFO] Installing system dependencies..."
apt-get update && apt-get install -y --no-install-recommends \
cmake \
build-essential
fi
fi
}
# check if running in docker
is_docker() {
[ -f /.dockerenv ] || \
......@@ -136,6 +157,13 @@ setup_conda_env() {
exit 1
fi
# check if _isaac_sim symlink exists and isaacsim-rl is not installed via pip
if [ ! -L "${ISAACLAB_PATH}/_isaac_sim" ] && ! python -m pip list | grep -q 'isaacsim-rl'; then
echo -e "[WARNING] _isaac_sim symlink not found at ${ISAACLAB_PATH}/_isaac_sim"
echo -e "\tThis warning can be ignored if you plan to install Isaac Sim via pip."
echo -e "\tIf you are using a binary installation of Isaac Sim, please ensure the symlink is created before setting up the conda environment."
fi
# check if the environment exists
if { conda env list | grep -w ${env_name}; } >/dev/null 2>&1; then
echo -e "[INFO] Conda environment named '${env_name}' already exists."
......@@ -273,6 +301,8 @@ while [[ $# -gt 0 ]]; do
# read the key
case "$1" in
-i|--install)
# install system dependencies first
install_system_deps
# install the python packages in IsaacLab/source directory
echo "[INFO] Installing extensions inside the Isaac Lab repository..."
python_exe=$(extract_python_exe)
......@@ -448,7 +478,7 @@ while [[ $# -gt 0 ]]; do
;;
-h|--help)
print_help
exit 1
exit 0
;;
*) # unknown option
echo "[Error] Invalid argument provided: $1"
......
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