Skip to content

Commit 87e34af

Browse files
committed
Remove previous installations on macos-arm64 before smoke testing
More arm64 changes test run under environment sleep 15min allow investigate add sleep test test Test test test Arm64 use python fix test testing test tests testing test test
1 parent 387228a commit 87e34af

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

.github/scripts/validate_binaries.sh

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,13 @@ else
77
conda activate ${ENV_NAME}
88
INSTALLATION=${MATRIX_INSTALLATION/"conda install"/"conda install -y"}
99

10-
# Make sure we remove previous installation if it exists
10+
export OLD_PATH=${PATH}
11+
# Workaround macos-arm64 runners. Issue: https://github.com/pytorch/test-infra/issues/4342
12+
if [[ ${TARGET_OS} == 'macos-arm64' ]]; then
13+
export PATH="${CONDA_PREFIX}/bin:${PATH}"
14+
fi
15+
16+
# Make sure we remove previous installation if it exists, this issue seems to affect only
1117
if [[ ${MATRIX_PACKAGE_TYPE} == 'wheel' ]]; then
1218
pip3 uninstall -y torch torchaudio torchvision
1319
fi
@@ -25,6 +31,10 @@ else
2531
python3 ./test/smoke_test/smoke_test.py
2632
fi
2733

34+
if [[ ${TARGET_OS} == 'macos-arm64' ]]; then
35+
export PATH=${OLD_PATH}
36+
fi
37+
2838
conda deactivate
2939
conda env remove -n ${ENV_NAME}
3040
fi

0 commit comments

Comments
 (0)