From ca1a5ad8bc612979059b4ad88d9db5030e778de9 Mon Sep 17 00:00:00 2001 From: Juan Garibay Date: Thu, 17 Sep 2026 16:51:43 -0400 Subject: [PATCH] fix(hooks): name the remedy in the blank-override failure The hook is global and this message blocks a push, so "ECC_PYTEST_CMD is set but names no command" left the operator holding a refusal with no next step. It now says to point the variable at a runner or unset it to fall back to discovery, which is the same advice the no-pytest-found branch already gives from the other direction. --- scripts/codex-git-hooks/pre-push | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/codex-git-hooks/pre-push b/scripts/codex-git-hooks/pre-push index 6a3d46152..6f04c2680 100755 --- a/scripts/codex-git-hooks/pre-push +++ b/scripts/codex-git-hooks/pre-push @@ -168,7 +168,8 @@ resolve_pytest() { # guess. Word-split, so the command names something on PATH or an interpreter # whose path has no spaces; a venv with spaces is found by the loop below. read -r -a PYTEST_CMD <<<"$ECC_PYTEST_CMD" || true - [[ ${#PYTEST_CMD[@]} -gt 0 ]] || fail "ECC_PYTEST_CMD is set but names no command" + [[ ${#PYTEST_CMD[@]} -gt 0 ]] || fail "ECC_PYTEST_CMD is set but names no command.\ + Point it at your test runner, or unset it to fall back to discovery." return 0 fi local venv