From 11f00b823ca3c6209fc4e180bd1324711317cd49 Mon Sep 17 00:00:00 2001 From: ethernet Date: Wed, 12 Aug 2026 04:23:43 -0400 Subject: [PATCH] fix(install-e2e): installer_supports lied under pipefail - buffer the probe git show | grep -qF exits at grep's first match; install.sh is ~140KB with the flag strings in the first few KB, so git show takes SIGPIPE on its next write and the pipeline reports 141 under set -o pipefail. The probe answered NO for flags the ref HAS - timing-dependent, green without pipefail (every local check), red on the runner. It hid while a probe miss just meant omitting --skip-browser; the first probe where NO is a hard failure (--include-desktop) exposed it on its first CI leg. Buffer git show into a variable and grep the string: git always completes, grep judges bytes. --- tests/install/installer-script-e2e.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/install/installer-script-e2e.sh b/tests/install/installer-script-e2e.sh index bc6078f3be..b07e36a4dc 100755 --- a/tests/install/installer-script-e2e.sh +++ b/tests/install/installer-script-e2e.sh @@ -155,8 +155,15 @@ INSTALL_DIR="$HERMES_HOME/hermes-agent" # install.sh rather than assuming this checkout's flag set: the point of the # matrix is to install releases from months back, whose installers predate # options we take for granted. +# +# Buffered through a variable, NOT `git show | grep -q`: under pipefail, +# grep -q exits at the first match (install.sh is ~140KB, the flags appear +# in the first few KB), git show takes SIGPIPE on its next write, and the +# pipeline reports 141 -- the probe answers NO for a flag the ref HAS. installer_supports() { - git -C "$REPO_ROOT" show "$1:scripts/install.sh" | grep -qF -- "$2" + local text + text="$(git -C "$REPO_ROOT" show "$1:scripts/install.sh")" + grep -qF -- "$2" <<< "$text" } run_installer() {