Refactor CopilotClientInfoLogger to minimize Reflection usage#38
Merged
Refactor CopilotClientInfoLogger to minimize Reflection usage#38
Conversation
- Use CopilotClientOptions parameter instead of reflection to access options - Use GetStatusAsync() API to get CLI version and protocol version info - Removed all Reflection usage from the logger - Simplified constructor to only require ILogger dependency - Changed interface method from sync to async (LogConnectionInfoAsync) - Updated App.cs to pass options and use async method - Updated unit tests accordingly Co-authored-by: SIkebe <17608272+SIkebe@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Refactor CopilotClientInfoLogger to minimize Reflection usage
Refactor CopilotClientInfoLogger to eliminate Reflection usage
Jan 23, 2026
Contributor
|
@copilot Reflection では出力されていたが、Reflection を使わない新しい実装では出力されなくなっている情報がないかチェックしてください。 |
- Keep options logging via passed CopilotClientOptions (no Reflection) - Keep GetStatusAsync() for CLI version info (no Reflection) - Restore process info logging (Reflection required - no SDK API): - CLI Process ID - CLI Command - CLI Arguments - Resolved CLI Path - Add comments documenting which Reflection is unavoidable Co-authored-by: SIkebe <17608272+SIkebe@users.noreply.github.com>
Contributor
Author
確認しました。以下のプロセス関連情報が欠落していたため、復元しました (7aaf21c): 欠落していた情報(Reflection で復元):
これらは SDK に公開 API がないため、Reflection を維持する必要があります。 最終的な出力情報:
|
Contributor
|
@copilot E2E テストの CLI の出力結果が GitHub Actions のログでも確認できるようにしてください。 |
Write CLI output to both ITestOutputHelper and Console so that E2E test results are visible in GitHub Actions logs. Co-authored-by: SIkebe <17608272+SIkebe@users.noreply.github.com>
Contributor
Author
Copilot
AI
changed the title
Refactor CopilotClientInfoLogger to eliminate Reflection usage
Refactor CopilotClientInfoLogger to minimize Reflection usage
Jan 23, 2026
Contributor
|
@copilot 出ていませんよ |
Add --logger "console;verbosity=detailed" to the E2E test command in the workflow to ensure CLI output is visible in GitHub Actions logs. Co-authored-by: SIkebe <17608272+SIkebe@users.noreply.github.com>
Contributor
Author
Contributor
The --logger "console;verbosity=detailed" in the workflow is sufficient to make ITestOutputHelper output visible in GitHub Actions logs. Co-authored-by: SIkebe <17608272+SIkebe@users.noreply.github.com>
Contributor
Author
Contributor
|
@copilot #region は使わないで |
Co-authored-by: SIkebe <17608272+SIkebe@users.noreply.github.com>
Contributor
Author
Document convention to not use #region/#endregion directives in C# code. Co-authored-by: SIkebe <17608272+SIkebe@users.noreply.github.com>
SIkebe
approved these changes
Jan 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces Reflection-based access to SDK internals with public APIs from github/copilot-sdk#77 where possible.
Changes
CopilotClientInfoLogger Refactoring
CopilotClientOptionsas parameter instead of reflecting on_optionsfieldGetStatusAsync()API for CLI version and protocol version (new output)E2E Test Visibility
--logger "console;verbosity=detailed"to workflow for GitHub Actions log outputCustom Instructions
#region/#endregionnot usedOriginal prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.