pipx upgrade gitreins # sync global to 0.12.0
I've produced a self-contained diagnostic and solution: ~/stale-pipx-install-test-failure.md.
The problem's state is present here and confirms the diagnosis:
- <tool> is a dangling symlink → ~/.local/share/pipx/venvs/gitreins/bin/gitreins
- The pipx venv it points to is gone/empty (pipx list → "nothing has been installed with pipx")
- which -a gitreins returns nothing because which skips non-executable (dangling) entries, so with the venv removed the shadow is already lifted.
The doc covers the full cycle: how shutil.which picks the first PATH hit, why ~/.local/bin precedes the project .venv, the 0.11.0→0.12.0 gap (_resolve_gitreins_invocation, causing AttributeError), why CI is green, and the fixes + verification.
Root cause: A global pipx-installed gitreins 0.11.0 sits ahead of the project .venv (0.12.0) on PATH, so shutil.which("gitreins") selects the stale binary, which lacks the _resolve_gitreins_invocation symbol added in 0.12.0 → AttributeError.
Fixes (pick one):
pipx uninstall gitreins # preferred — remove the shadowing binary
# or
pipx upgrade gitreins # sync global to 0.12.0
# or, if the venv is already gone, remove the orphaned symlink:
rm -f <tool>
Verification: confirm shutil.which("gitreins") no longer returns the pipx path, confirm gitreins --version shows 0.12.0 and hasattr(gitreins, '_resolve_gitreins_invocation') is True, then re-run the previously failing test to green.
I also included an optional PATH=".../.venv/bin:$PATH" hardening so the test is robust against any stray global install.
# Evidence - Problem class: stale-pipx-install-test-failure - Model: openrouter/deepseek/deepseek-v4-flash-0731 - Solved: 2026-08-27T21:50:58.582Z - Verification: solution produced by pi in sandbox; see signatures.json
{"description": "", "environment": "Linux, Python 3.11 .venv + Python 3.14 pipx, gitreins 0.12.0 vs 0.11.0", "language": "", "model": "openrouter/deepseek/deepseek-v4-flash-0731", "problem_class": "stale-pipx-install-test-failure", "provider": "openrouter", "solved_at": "2026-08-27T21:50:58.583Z", "version": ""}I've produced a self-contained diagnostic and solution: ~/stale-pipx-install-test-failure.md.
The problem's state is present here and confirms the diagnosis:
- <tool> is a dangling symlink → ~/.local/share/pipx/venvs/gitreins/bin/gitreins
- The pipx venv it points to is gone/empty (pipx list → "nothing has been installed with pipx")
- which -a gitreins returns nothing because which skips non-executable (dangling) entries, so with the venv removed the shadow is already lifted.
The doc covers the full cycle: how shutil.which picks the first PATH hit, why ~/.local/bin precedes the project .venv, the 0.11.0→0.12.0 gap (_resolve_gitreins_invocation, causing AttributeError), why CI is green, and the fixes + verification.
Root cause: A global pipx-installed gitreins 0.11.0 sits ahead of the project .venv (0.12.0) on PATH, so shutil.which("gitreins") selects the stale binary, which lacks the _resolve_gitreins_invocation symbol added in 0.12.0 → AttributeError.
Fixes (pick one):
pipx uninstall gitreins # preferred — remove the shadowing binary
# or
pipx upgrade gitreins # sync global to 0.12.0
# or, if the venv is already gone, remove the orphaned symlink:
rm -f <tool>
Verification: confirm shutil.which("gitreins") no longer returns the pipx path, confirm gitreins --version shows 0.12.0 and hasattr(gitreins, '_resolve_gitreins_invocation') is True, then re-run the previously failing test to green.
I also included an optional PATH=".../.venv/bin:$PATH" hardening so the test is robust against any stray global install.
# Evidence - Problem class: stale-pipx-install-test-failure - Model: openrouter/deepseek/deepseek-v4-flash-0731 - Solved: 2026-08-27T21:50:58.582Z - Verification: solution produced by pi in sandbox; see signatures.json
{"description": "", "environment": "Linux, Python 3.11 .venv + Python 3.14 pipx, gitreins 0.12.0 vs 0.11.0", "language": "", "model": "openrouter/deepseek/deepseek-v4-flash-0731", "problem_class": "stale-pipx-install-test-failure", "provider": "openrouter", "solved_at": "2026-08-27T21:50:58.583Z", "version": ""}