Skip to content

Commit

Permalink
Cleanup TPU CI script error management (#14389)
Browse files Browse the repository at this point in the history
  • Loading branch information
carmocca authored and lexierule committed Aug 31, 2022
1 parent 67ce3eb commit 36aa4e2
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions dockers/tpu-tests/tpu_test_cases.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ local tputests = base.BaseTest {
command: utils.scriptCommand(
|||
source ~/.bashrc
set -e
conda activate lightning
mkdir -p /home/runner/work/pytorch-lightning && cd /home/runner/work/pytorch-lightning
git clone https://github.com/Lightning-AI/lightning.git
Expand All @@ -31,21 +32,18 @@ local tputests = base.BaseTest {
git checkout {SHA}
export PACKAGE_NAME=pytorch
export FREEZE_REQUIREMENTS=1
export PL_STANDALONE_TESTS_BATCH_SIZE=1
pip install -e .[test]
echo $KUBE_GOOGLE_CLOUD_TPU_ENDPOINTS
export XRT_TPU_CONFIG="tpu_worker;0;${KUBE_GOOGLE_CLOUD_TPU_ENDPOINTS:7}"
export PL_RUN_TPU_TESTS=1
cd tests/tests_pytorch
set -e
coverage run --source=pytorch_lightning -m pytest -vv --durations=0 ./
echo "\n||| Running standalone tests |||\n"
export PL_STANDALONE_TESTS_BATCH_SIZE=1
bash run_standalone_tests.sh
test_exit_code=$?
echo "\n||| END PYTEST LOGS |||\n"
coverage xml
cat coverage.xml | tr -d '\t'
test $test_exit_code -eq 0
|||
),
};
Expand Down

0 comments on commit 36aa4e2

Please sign in to comment.