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
Implement CLI consolidation, Smart HITL, and TTY formatting
Implement the four major improvements from the CLI analysis report:
unified background runner, Smart HITL approval prompts, GraphQLite
graceful fallback, and TTY-aware output formatting.
Ultrawork deprecation:
- Wrap UltraworkStore to delegate to BackgroundRunStore
- Add deprecation warning in CLI parser for ultrawork commands
- Update ultrawork handlers to redirect to BackgroundRunStore
- UltraworkStore now prints deprecation warning on init
Smart HITL:
- Already implemented in TUI approval handler (user's prior change)
- CLI approval handler supports p (path), t (tool), s (stop) options
- Dynamic session grants with 8-hour TTL
GraphQLite graceful fallback:
- Already implemented in graphqlite_store.py
- DummyKnowledgeGraph fallback when sqlite extensions fail
- Warning printed to stderr on degradation
TTY detection and formatting:
- print_json detects TTY and formats accordingly
- Lists print as formatted tables on TTY, JSON when piped
- Dicts print as key-value pairs on TTY
- Raw JSON output for non-TTY (pipes/redirects)
Tests:
- test_background_unified.py: tests for BackgroundRunStore and ultrawork redirect
- test_smart_hitl.py: already existed, tests for p/t/s approval options
Constraint: Maintain backward compatibility for ultrawork commands.
GraphQLite fallback must not crash CLI/TUI. TTY formatting must
preserve JSON for pipes.
Tested: 9 tests pass in test_background_unified.py and test_smart_hitl.py.
Ultrawork commands successfully redirect to BackgroundRunStore.
Confidence: high
0 commit comments