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
{{ message }}
Repository navigation
[plan] Standardize error messages to use console.FormatErrorMessage() #11625
Convert all user-facing error messages to use console.FormatErrorMessage() and ensure they go to stderr for consistency.
Context
From discussion #11611: Multiple CLI files use direct fmt.Printf for error messages instead of the standardized console formatting. This affects user experience and consistency.
Files with Issues: commands.go, git.go, file_tracker.go, run_workflow_tracking.go
Approach
Audit each file for error message patterns:
Search for fmt.Printf with error-related text
Identify messages that should use console.FormatErrorMessage()
Ensure output goes to stderr
Convert error messages:
Use fmt.Fprintln(os.Stderr, console.FormatErrorMessage(...))
Maintain clear, actionable error messages
Ensure proper error wrapping with %w
Test changes:
Verify errors display correctly in terminal
Test non-TTY mode strips ANSI codes
Run existing tests to ensure no regressions
Files to Modify
Update: pkg/cli/commands.go
Update: pkg/cli/git.go
Update: pkg/cli/file_tracker.go
Update: pkg/cli/run_workflow_tracking.go
Pattern to Follow
// ❌ WRONG - Direct fmt.Printf without console formatting:fmt.Printf("Error: Failed to process workflow: %v\n", err)
// ✅ CORRECT - Console formatted error to stderr:fmt.Fprintln(os.Stderr, console.FormatErrorMessage(err.Error()))
// ✅ CORRECT - With context:fmt.Fprintln(os.Stderr, console.FormatErrorMessage(fmt.Sprintf("Failed to process workflow: %v", err)))
Acceptance Criteria
All error messages in commands.go use console formatting
All error messages in git.go use console formatting
All error messages in file_tracker.go use console formatting
All error messages in run_workflow_tracking.go use console formatting
Activity
github-actions commentedon Jan 24, 2026
🍪 Issue Monster has assigned this to Copilot!
I've identified this issue as a good candidate for automated resolution and assigned it to the Copilot agent.
The Copilot agent will analyze the issue and create a pull request with the fix.
Om nom nom! 🍪