You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: add robust fallback from global to npx execution
When the global promptfoo executable fails to run (OSError, PermissionError),
automatically fall back to npx. This handles edge cases like:
- Resource temporarily unavailable (errno 35/EAGAIN on macOS)
- Executable not ready immediately after npm install -g
- Permission issues
- Any other execution failures
The wrapper now works reliably in all scenarios:
1. Global install exists and works: use it (fastest)
2. Global install exists but fails: fall back to npx (reliable)
3. No global install: use npx directly (works whether promptfoo is cached or not)
This ensures the wrapper works whether promptfoo is pre-installed or being
installed for the first time via npx.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
0 commit comments