From f149cf9cf476ef2043abc3dfa30480c92d110961 Mon Sep 17 00:00:00 2001 From: Andreas Karlsson Date: Fri, 30 May 2025 19:00:56 +0200 Subject: [PATCH 1/4] Fix broken code coverage job An extra space had snuck into the script. --- ci_scripts/make-build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci_scripts/make-build.sh b/ci_scripts/make-build.sh index 63b139e805957..9fa762033138b 100755 --- a/ci_scripts/make-build.sh +++ b/ci_scripts/make-build.sh @@ -6,7 +6,7 @@ for arg in "$@" do case "$arg" in --enable-coverage) - ARGS +=" --enable-coverage" + ARGS+=" --enable-coverage" ;; esac done From ee7bd1f2c112b9ed3e4a02d6edf52e11372970d0 Mon Sep 17 00:00:00 2001 From: Andreas Karlsson Date: Fri, 30 May 2025 19:07:31 +0200 Subject: [PATCH 2/4] Run installation of llvm as root it is unclear why it seemed to work but when adding "set -e" we got an error from the script. --- ci_scripts/ubuntu-deps.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci_scripts/ubuntu-deps.sh b/ci_scripts/ubuntu-deps.sh index 4646bee3ad423..898028675e897 100755 --- a/ci_scripts/ubuntu-deps.sh +++ b/ci_scripts/ubuntu-deps.sh @@ -53,7 +53,7 @@ DEPS=( sudo apt-get update sudo apt-get install -y ${DEPS[@]} -bash -c "$(wget -O - https://apt.llvm.org/llvm.sh)" +sudo bash -c "$(wget -O - https://apt.llvm.org/llvm.sh)" pip3 install meson # Vault From 0f5bf629800780299fd29f549e1305c16a17bb18 Mon Sep 17 00:00:00 2001 From: Andreas Karlsson Date: Fri, 30 May 2025 21:05:24 +0200 Subject: [PATCH 3/4] Disable checking indentation of upstream code The upstream code has been incorrectly indented since PostgreSQL 17.4 but the lack of set -e in the script hid that from us. --- ci_scripts/run-pgindent.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ci_scripts/run-pgindent.sh b/ci_scripts/run-pgindent.sh index 4b9ba00f278b8..d93784dcbefbe 100755 --- a/ci_scripts/run-pgindent.sh +++ b/ci_scripts/run-pgindent.sh @@ -17,7 +17,8 @@ cd "$SCRIPT_DIR/.." export PATH=$SCRIPT_DIR/../src/tools/pgindent/:$INSTALL_DIR/bin/:$PATH # Check everything except pg_tde with the list in the repo -pgindent --typedefs=src/tools/pgindent/typedefs.list --excludes=<(echo "contrib/pg_tde") "$@" . +# TODO: Disabled due to incorrectly indented upsrteam as of 17.4 +#pgindent --typedefs=src/tools/pgindent/typedefs.list --excludes=<(echo "contrib/pg_tde") "$@" . # Check pg_tde with the fresh list extraxted from the object file pgindent --typedefs=combined.typedefs "$@" contrib/pg_tde From f6f2c9886659cb2916ed88da7b5768ea44283050 Mon Sep 17 00:00:00 2001 From: Andreas Karlsson Date: Fri, 30 May 2025 19:03:25 +0200 Subject: [PATCH 4/4] Consistently use set -e in all our scripts It recently hid a bug in the code coverage job. --- ci_scripts/backup/pg_basebackup_test.sh | 1 + ci_scripts/configure-global-tde.sh | 1 + ci_scripts/dump-typedefs.sh | 2 ++ ci_scripts/make-build.sh | 2 ++ ci_scripts/make-test-global-tde.sh | 1 + ci_scripts/meson-build.sh | 2 ++ ci_scripts/run-pgindent.sh | 2 ++ ci_scripts/run-pgperltidy.sh | 2 ++ ci_scripts/setup-keyring-servers.sh | 2 ++ ci_scripts/ubuntu-deps.sh | 2 ++ 10 files changed, 17 insertions(+) diff --git a/ci_scripts/backup/pg_basebackup_test.sh b/ci_scripts/backup/pg_basebackup_test.sh index a9b4f4199fe95..23b2ca28231dc 100755 --- a/ci_scripts/backup/pg_basebackup_test.sh +++ b/ci_scripts/backup/pg_basebackup_test.sh @@ -1,4 +1,5 @@ #!/bin/bash + set -e # Exit on errors set -u # Treat unset variables as errors set -o pipefail # Stop on pipeline errors diff --git a/ci_scripts/configure-global-tde.sh b/ci_scripts/configure-global-tde.sh index 40d4cdbd26dd5..4d4b0648903c1 100644 --- a/ci_scripts/configure-global-tde.sh +++ b/ci_scripts/configure-global-tde.sh @@ -1,4 +1,5 @@ #!/bin/bash + set -e SCRIPT_DIR="$(cd -- "$(dirname "$0")" >/dev/null 2>&1; pwd -P)" diff --git a/ci_scripts/dump-typedefs.sh b/ci_scripts/dump-typedefs.sh index 6f854a4889570..eabe70815d9c8 100755 --- a/ci_scripts/dump-typedefs.sh +++ b/ci_scripts/dump-typedefs.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + SCRIPT_DIR="$(cd -- "$(dirname "$0")" >/dev/null 2>&1; pwd -P)" cd "$SCRIPT_DIR/.." diff --git a/ci_scripts/make-build.sh b/ci_scripts/make-build.sh index 9fa762033138b..79b5cf9281666 100755 --- a/ci_scripts/make-build.sh +++ b/ci_scripts/make-build.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + ARGS= for arg in "$@" diff --git a/ci_scripts/make-test-global-tde.sh b/ci_scripts/make-test-global-tde.sh index ee4a8787fbf5c..ef090a7ba7481 100755 --- a/ci_scripts/make-test-global-tde.sh +++ b/ci_scripts/make-test-global-tde.sh @@ -1,6 +1,7 @@ #!/bin/bash set -e + ADD_FLAGS= for arg in "$@" diff --git a/ci_scripts/meson-build.sh b/ci_scripts/meson-build.sh index 1cd3145a04b93..6cce676fabf32 100755 --- a/ci_scripts/meson-build.sh +++ b/ci_scripts/meson-build.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + ENABLE_COVERAGE= for arg in "$@" diff --git a/ci_scripts/run-pgindent.sh b/ci_scripts/run-pgindent.sh index d93784dcbefbe..77617e558cb0c 100755 --- a/ci_scripts/run-pgindent.sh +++ b/ci_scripts/run-pgindent.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + SCRIPT_DIR="$(cd -- "$(dirname "$0")" >/dev/null 2>&1; pwd -P)" INSTALL_DIR="$SCRIPT_DIR/../../pginst" cd "$SCRIPT_DIR/../" diff --git a/ci_scripts/run-pgperltidy.sh b/ci_scripts/run-pgperltidy.sh index c59d50cc2a8f0..e7a84018129db 100755 --- a/ci_scripts/run-pgperltidy.sh +++ b/ci_scripts/run-pgperltidy.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + SCRIPT_DIR="$(cd -- "$(dirname "$0")" >/dev/null 2>&1; pwd -P)" cd "$SCRIPT_DIR/../" diff --git a/ci_scripts/setup-keyring-servers.sh b/ci_scripts/setup-keyring-servers.sh index 81caf4003f89c..c9f523c8129e8 100755 --- a/ci_scripts/setup-keyring-servers.sh +++ b/ci_scripts/setup-keyring-servers.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + SCRIPT_DIR="$(cd -- "$(dirname "$0")" >/dev/null 2>&1; pwd -P)" cd /tmp diff --git a/ci_scripts/ubuntu-deps.sh b/ci_scripts/ubuntu-deps.sh index 898028675e897..d998289a55163 100755 --- a/ci_scripts/ubuntu-deps.sh +++ b/ci_scripts/ubuntu-deps.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + DEPS=( # Setup wget