From 2dc7afe70762ddefd69c5ebbf15eea4cc3669fa4 Mon Sep 17 00:00:00 2001 From: garrytan Date: Tue, 13 Oct 2026 04:15:25 +0000 Subject: [PATCH] fix(capy-install): the install reason names the project's pin and gstack's real minimum Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> --- bin/gstack-capy-install | 2 +- test/gstack-capy-install.test.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/gstack-capy-install b/bin/gstack-capy-install index ca8399b55..78a0bd854 100755 --- a/bin/gstack-capy-install +++ b/bin/gstack-capy-install @@ -158,7 +158,7 @@ if printf '%s\n' "$PINS_OUT" | grep -q '^PINS_VERDICT: '; then $(printf '%s\n' "$PINS_OUT" | sed -n 's/^PIN: bun \([^ ]*\) exact \([^ ]*\) lane=[a-z]*$/\1 \2/p') EOF_PINS pins_ok "$WANT" || stop RUNTIME_PIN_CONFLICT "Bun conflict: gstack needs >=$WANT, $PROJECT pins $(printf '%s\n' "$PINS_OUT" | sed -n 's/^PIN_SUMMARY: //p' | grep '^bun' | tr '\n' ';' | sed 's/;$//')" "raise the project's pin to $WANT or newer, or install gstack on a machine the project accepts" - if [ "$LD_VER" = "$WANT" ]; then reuse_ld; else install_bun "bun ${HAVE:-absent} does not satisfy the project pins (or gstack's minimum $WANT)"; fi + if [ "$LD_VER" = "$WANT" ]; then reuse_ld; else install_bun "bun ${HAVE:-absent} does not satisfy the project pins (bun $WANT) or gstack's minimum $GSTACK_BUN_TESTED"; fi fi else # No pin report (no project, or a Bun that cannot run the parser): the diff --git a/test/gstack-capy-install.test.ts b/test/gstack-capy-install.test.ts index 02a703805..0b190e68a 100644 --- a/test/gstack-capy-install.test.ts +++ b/test/gstack-capy-install.test.ts @@ -171,6 +171,7 @@ describe('gstack-capy-install', () => { expect(sh(`cd "${f.base}/z" && zip -qr "${zip}" bun-linux-x64`).status).toBe(0); const adopted = run(f, ['--project', project], { STUB_CURL_ZIP: zip }); expect(adopted.stdout).toContain('installing bun 1.4.3 from its release archive'); + expect(adopted.stdout).not.toContain("gstack's minimum 1.4.3"); expect(f.calls().filter(l => l.startsWith('curl '))).toEqual([expect.stringContaining('https://github.com/oven-sh/bun/releases/download/bun-v1.4.3/bun-linux')]); expect(adopted.status).toBe(3); expect(adopted.stderr).toContain('SHA-256 mismatch');