Release Date: July 28, 2025
Type: Major Release - Interactive Utils Migration
Version 1.5.0 completes the migration of all critical Python tools to use the unified interactive_utils.py module, eliminating EOF errors in CI/CD environments and providing consistent non-interactive mode handling across the entire toolkit.
All critical tools now handle non-interactive environments gracefully:
- No More EOF Crashes - Clear, actionable error messages instead of cryptic failures
- Automatic CI/CD Detection - Recognizes GitHub Actions, GitLab CI, Jenkins, and more
- Unified Configuration - Same patterns work across all tools
- Multiple Prompt Types - Yes/no, typed phrases, numbered selections, multi-choice
-
text_undo.py
- Numbered selection menus for restore operations
- Full environment variable and config file support
-
safe_file_manager.py
- Risk-based confirmations with typed phrases for high-risk operations
- Automatic mode selection based on operation risk level
-
safegit.py
- Multi-choice prompts (1/2/3 options)
- Typed confirmations for dangerous git operations
- Graduated safety levels with appropriate prompts
-
replace_text_v9.py
- Large change confirmations with configurable thresholds
- Automatic detection of batch operations
-
replace_text_ast_v3.py
- Batch operation confirmations with y/n/q support
- Per-file confirmation options for granular control
Tools now support configuration in priority order:
-
Command-line flags (highest priority)
./run_any_python_tool.sh tool_name.py --yes
-
Environment variables
export TOOL_NAME_ASSUME_YES=1 ./run_any_python_tool.sh tool_name.py -
Tool-specific .pytoolsrc
[tool_name] assume_yes = true
-
Global .pytoolsrc defaults
[defaults] non_interactive = true
-
Hard-coded defaults (interactive by default)
The new shared module provides:
# Core functions
is_interactive() # Auto-detect environment
safe_input() # EOF-safe input handling
get_confirmation() # Yes/no prompts
get_multi_choice() # Multiple choice (y/n/q)
get_numbered_selection() # Numbered menu selections
check_auto_yes_env() # Environment variable supportBefore (v1.4.0):
EOFError: EOF when reading a line
After (v1.5.0):
❌ ERROR: Interactive confirmation required but running in non-interactive mode.
Use --yes flag to skip confirmation
Or set TOOL_NAME_ASSUME_YES=1 environment variable
Or set 'assume_yes = true' in .pytoolsrc [tool_name] section
For tools not yet migrated:
-
Import interactive_utils with fallback:
try: from interactive_utils import get_confirmation except ImportError: # Fallback implementation
-
Replace
input()calls:# Before response = input("Continue? [y/N]: ") # After confirmed = get_confirmation("Continue?", tool_name="my_tool")
-
Add environment variable support:
check_auto_yes_env('my_tool', args)
- 100% EOF Error Elimination in migrated tools
- Consistent UX across all interactive prompts
- CI/CD Ready out of the box
- Backward Compatible with all existing workflows
Special thanks to all contributors who helped test and refine the interactive utils system, making the Code Intelligence Toolkit more robust and CI/CD friendly.
For questions or issues, please open an issue on GitHub.