Skip to content

[log] Add debug logging to copilot permissions, gh-aw-ref resolution, and add command - #56241

Merged
pelikhan merged 2 commits into
mainfrom
add-debug-logging-cli-add-commands-7d681d9273f76b3d
Aug 27, 2026
Merged

[log] Add debug logging to copilot permissions, gh-aw-ref resolution, and add command#56241
pelikhan merged 2 commits into
mainfrom
add-debug-logging-cli-add-commands-7d681d9273f76b3d

Conversation

@github-actions

@github-actions github-actions Bot commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR adds debug logging instrumentation (via pkg/logger) to three CLI files involved in the gh aw add command: the top-level add command, Copilot permission injection, and --gh-aw-ref resolution. It also fixes a minor code smell where the modified return value from applyFrontmatterLineTransform was previously discarded.

Change Classification

  • Type: infra
  • Scope: pkg/cli (add command, copilot permissions, gh-aw-ref resolution)
  • Breaking: No

Key Changes

File Change Impact
pkg/cli/add_command.go Added debug log lines for workflow source count/flags and failure during resolved-workflow installation Low
pkg/cli/add_copilot_permissions.go Added copilotPermissionsLog logger; logs injection failure and success (with modified flag); now captures previously-discarded modified value Low
pkg/cli/add_gh_aw_ref.go Added addGhAwRefLog logger; logs ref resolution start, failure, and resolved SHA Low

Impact Assessment

  • No downstream impact identified. Changes only add DEBUG-gated log output (namespaces cli:add_copilot_permissions, cli:add_gh_aw_ref) and do not alter control flow, error behavior, or public APIs.
  • Aids future debugging of gh aw add failures related to Copilot permission injection and --gh-aw-ref resolution.

Commits

7fd116e44 Merge branch 'main' into add-debug-logging-cli-add-commands-7d681d9273f76b3d
28c6907d1 Add debug logging to copilot permissions, gh-aw-ref resolution, and add command

Generated by PR Description Updater for #56241 · copilot · auto · 22.9 AIC · ⌖ 5.44 AIC · ⊞ 7.7K ·

…dd command

Instruments three pkg/cli files that had no or unused pkg/logger wiring:
copilot-requests permission injection outcomes, --gh-aw-ref resolution,
and the add command's top-level entry/failure points.
@pelikhan
pelikhan merged commit a0cef04 into main Aug 27, 2026
2 checks passed
@pelikhan
pelikhan deleted the add-debug-logging-cli-add-commands-7d681d9273f76b3d branch August 27, 2026 06:23
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