Skip to content

[log] Add debug logging to metrics, observability, and workflow compilation#23785

Merged
pelikhan merged 1 commit intomainfrom
go-logger-enhancement-2026-03-31-f109b9d1ce78c4b3
Mar 31, 2026
Merged

[log] Add debug logging to metrics, observability, and workflow compilation#23785
pelikhan merged 1 commit intomainfrom
go-logger-enhancement-2026-03-31-f109b9d1ce78c4b3

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

Enhanced debug logging in 5 key files to improve troubleshooting and visibility into workflow compilation and analysis:

  • pkg/cli/audit_cross_run.go: Log entry and computed results (avg cost/tokens/turns, spike counts) in buildMetricsTrend
  • pkg/cli/observability_insights.go: Log when failure/drift hotspots are detected and log total insight counts at function return
  • pkg/workflow/command.go: Log the number of command checks built and which condition path is taken (simple vs event-aware)
  • pkg/workflow/safe_outputs_tools_repo_params.go: Log entry, skip decision, and result of repo parameter computation in both addRepoParameterIfNeeded and computeRepoParamForTool
  • pkg/workflow/imports.go: Log entry and completion of mergeSafeOutputConfig when merging imported safe-output configurations

All changes follow project conventions (file-specific logger variables, pkg:filename naming, no side effects in log arguments). Build validated with make build and go build ./....

Test plan

  • make build passes with no compilation errors
  • go build ./... succeeds
  • DEBUG=workflow:command,workflow:safe_outputs_config shows new log output during workflow compilation
  • DEBUG=cli:audit_cross_run,cli:observability_insights shows new log output during audit report generation

🤖 Generated with [Claude Code]((claude.com/redacted)

Generated by Go Logger Enhancement ·

  • expires on Apr 2, 2026, 9:38 PM UTC

- audit_cross_run: log entry and spike detection results in buildMetricsTrend
- observability_insights: log hotspot detection and final insight counts
- command: log number of checks built and condition path chosen
- safe_outputs_tools_repo_params: log entry, skip, and result of repo param computation
- imports: log entry and completion of mergeSafeOutputConfig

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions github-actions bot added automation enhancement New feature or request labels Mar 31, 2026
@pelikhan pelikhan merged commit aa79607 into main Mar 31, 2026
@pelikhan pelikhan deleted the go-logger-enhancement-2026-03-31-f109b9d1ce78c4b3 branch March 31, 2026 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automation enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant