python3 not found on Windows (Git Bash) — codex skills fail on first run
- Dominant language
- TypeScript
- Stars
- 133k
- Forks
- 19.9k
- Avg merge
- 18h 46m
- Merged PRs (30d)
- 26
Description
## Bug
The `/codex` skill hardcodes `python3` in its Bash pipe commands for parsing codex JSON output. On Windows (Git Bash / MSYS2), Python installs as `python`, not `python3`, causing:
```
/usr/bin/bash: line 238: python3: command not found
```
The skill fails on first invocation, then sometimes works on retry (likely due to shell environment initialization quirks).
## Affected files
- `codex/SKILL.md.tmpl` — 3 instances (lines ~290, ~434, ~476)
All are the same pattern:
```bash
... | PYTHONUNBUFFERED=1 python3 -u -c "
```
## Suggested fix
Replace bare `python3` with a cross-platform probe:
```bash
PYTHON_CMD=$(command -v python3 2>/dev/null || command -v python 2>/dev/null || echo python)
... | PYTHONUNBUFFERED=1 $PYTHON_CMD -u -c "
```
This tries `python3` first (Linux/macOS), falls back to `python` (Windows), and fails clearly if neither exists.
## Environment
- Windows 11, Git Bash (MSYS2)
- Python 3.11.6 installed as `python` (standard Windows installer)
- gstack v1.26.0.0
Contributor guide
Assessment
This issue has not been assessed yet.