From 7fab376127b17fe2043f7b36f46066bd3dde1fa3 Mon Sep 17 00:00:00 2001 From: Russell Bryant Date: Fri, 18 Oct 2024 19:08:44 +0000 Subject: [PATCH] [CI/Build] Make mypy job fail when errors occur Fix `tools/mypy.sh` to fail when any command fails when running in CI. Signed-off-by: Russell Bryant --- tools/mypy.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/mypy.sh b/tools/mypy.sh index d69b61c7f34fc..14b0976a27da5 100755 --- a/tools/mypy.sh +++ b/tools/mypy.sh @@ -2,6 +2,10 @@ CI=${1:-0} +if [ $CI -eq 1 ]; then + set -e +fi + run_mypy() { echo "Running mypy on $1" if [ $CI -eq 1 ] && [ -z "$1" ]; then