[terminal-stylist] Terminal Stylist Report: Console Output Consistency Analysis #36601
Replies: 2 comments
-
|
💥 WHOOSH! The Smoke Test Agent BURST onto the scene! 🦸 KA-POW! 💢 All systems checked — Claude engine running at full power! The Agent zoomed through MCP servers, leapt over build steps, and landed a perfect snapshot! 🎯 "This discussion has been officially smoke-tested!" — THE END... or IS it?! 📖✨ Warning Firewall blocked 6 domainsThe following domains were blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "accounts.google.com"
- "android.clients.google.com"
- "clients2.google.com"
- "contentautofill.googleapis.com"
- "safebrowsingohttpgateway.googleapis.com"
- "www.google.com"See Network Configuration for more information.
|
Beta Was this translation helpful? Give feedback.
-
|
Smoke-test sprite was here: buttons booped, logs sniffed, sparkles deployed. ✨🤖 Warning Firewall blocked 6 domainsThe following domains were blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "accounts.google.com"
- "android.clients.google.com"
- "clients2.google.com"
- "contentautofill.googleapis.com"
- "safebrowsingohttpgateway.googleapis.com"
- "www.google.com"See Network Configuration for more information.
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
This report summarizes the console output patterns found across 879 non-test Go source files in
github/gh-aw, with focus on consistency, Lipgloss v2 usage, and Huh form implementations.Key Metrics
console.*formattersconsole.Format*call sitesfmt.Fprintf(os.Stderr, ...)(no formatter)Strengths ✅
1. Well-designed
pkg/consolepackageThe console package is the clear centerpiece of CLI output. It provides:
applyStyle()— styles silently degrade when piped^pointersstyles.LightDark()throughoutpkg/stylesRenderTable,RenderTitleBox,RenderErrorBox,RenderInfoSection,RenderComposedSections— rich layout utilities built on Lipgloss v22. Consistent
console.Format*adoptionThe most-used formatters show strong adoption:
console.FormatInfoMessageconsole.FormatWarningMessageconsole.FormatSuccessMessageconsole.FormatVerboseMessageconsole.FormatErrorMessageconsole.FormatCommandMessageconsole.FormatProgressMessage3. Lipgloss v2 best practices followed
pkg/styles/theme.gousescompat.AdaptiveColorfor all semantic colors, ensuring readability in both light/dark themeslipgloss.LightDark(isDark)is correctly used inHuhThemeto build all adaptive color valuespkg/console/spinner.gouses Bubble Tea +charm.land/bubbles/v2/spinnerfor idiomatic animationpkg/cli/compile_schedule_calendar.gochecksisTerminalbefore applyinglipgloss.Style, then returnslipgloss.NewStyle()(no-op) for non-TTYpkg/cli/gateway_logs_timeline_render.godefines astreamStyleRendererinterface for rendering without direct lipgloss coupling in helpers4. Huh forms with custom themed styles
Three files use
charm.land/huh/v2forms:add_interactive_workflow.go— Confirm dialog for workflow creationadd_interactive_schedule.go— Select field for schedule frequencyadd_interactive_git.go— Select for merge actionsAll leverage
pkg/styles.HuhTheme, a fullhuh.ThemeFuncthat maps the Dracula/adaptive palette to every Huh style state (Focused, Blurred, Group).Areas for Improvement⚠️
251 raw
fmt.Fprintf(os.Stderr, ...)calls bypassing console formattersThe top offenders are:
pkg/cli/mcp_inspect_mcp.gopkg/cli/audit_report_render.gopkg/cli/audit_cross_run_render.gopkg/cli/compile_stats.gopkg/cli/enable.gopkg/cli/deps_report.gopkg/cli/add_interactive_workflow.gopkg/cli/experiments_analyze_statistics.goExamples of output that should use console formatters:
Inline debug traces should use
pkg/logger, notfmt.FprintfSeveral files in
add_interactive_workflow.goemit diagnostic traces unconditionally:These should use
logger.New("cli:add_interactive_workflow")so they are gated behindDEBUG=cli:*and don't pollute normal output.Markdown bold syntax in raw stderr output (
mcp_inspect_mcp.go)Several lines embed Markdown bold syntax (
**Name:**) that renders as literal asterisks in terminals. Since the output targets stderr (a terminal stream), Lipgloss bold styling is the correct approach:Minor:
compile_schedule_calendar.godirect Lipgloss calls vs. console packagecompile_schedule_calendar.gocorrectly gates styles withisTerminal, but writes directly to stderr viafmt.Fprintln(os.Stderr, row.String())rather than routing through the console package. Since the calendar render is bespoke (grid layout), this is defensible — but extracting it into aconsole.RenderCalendar()helper would improve testability and centralize TTY logic.Recommendations
Migrate
mcp_inspect_mcp.go— Replace 37 rawfmt.Fprintfcalls withconsole.Format*equivalents. The tool inspection output uses emojis and Markdown bold that should be proper Lipgloss styles.Adopt
pkg/loggerfor debug traces inadd_interactive_workflow.go— The 12 raw debug writes are unconditionally visible to users; they should beDEBUG=cli:*-gated.Audit
audit_report_render.goandaudit_cross_run_render.go— These render structured run data inline; adoptingconsole.FormatVerboseMessageorconsole.RenderTablewhere appropriate would improve visual consistency.Consider
console.FormatListItem— Only 3 usages found. Manual bullet" • "strings appear in several files that could use this formatter.Continue using
HuhTheme— The custom huh theme is excellent. All three Huh-using files already use it correctly withhuh.NewForm(...).WithTheme(styles.HuhTheme).References: §26878171779
Beta Was this translation helpful? Give feedback.
All reactions