Skip to content

Add API descriptions #301

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed

Add API descriptions #301

wants to merge 2 commits into from

Conversation

phecke
Copy link
Member

@phecke phecke commented May 20, 2025

For types and members that are missing summary code comment descriptions.

@Copilot Copilot AI review requested due to automatic review settings May 20, 2025 21:19
@phecke phecke requested a review from a team as a code owner May 20, 2025 21:19
@github-actions github-actions bot added ML: Samples Tags changes to samples ML: Core Tags changes to core libraries ML: Tests Tags changes to tests labels May 20, 2025
@phecke phecke self-assigned this May 20, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR standardizes XML documentation by fully qualifying exception types in <exception> tags across various libraries.

  • Prefixes exception cref attributes with System. to avoid ambiguity.
  • Aligns exception documentation formatting consistently.
  • Applies changes in REST clients, state management, adapters, and builder components.

Reviewed Changes

Copilot reviewed 33 out of 33 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/libraries/Client/Microsoft.Agents.Connector/RestClients/AttachmentsRestClient.cs Qualified exception types in doc comments
src/libraries/Client/Microsoft.Agents.Client/IAgentHost.cs Qualified ArgumentException in interface docs
src/libraries/Builder/Microsoft.Agents.Builder/UserAuth/TokenService/OAuthFlow.cs Qualified TimeoutException in method docs
src/libraries/Builder/Microsoft.Agents.Builder/RestChannelServiceClientFactory.cs Qualified multiple exceptions in factory docs
src/libraries/Builder/Microsoft.Agents.Builder/LocalArrayBufferWritter.cs Qualified ArgumentException and InvalidOperationException in class docs

@@ -76,7 +76,7 @@ await SendOAuthCardAsync(
/// active after the turn has been processed.
/// <para>The prompt generally continues to receive the user's replies until it accepts the
/// user's reply as valid input for the prompt.</para></remarks>
/// <exception cref="TimeoutException"/>
/// <exception cref="System.TimeoutException"/>
Copy link
Preview

Copilot AI May 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Provide a description for this exception, for example: 'Thrown when the OAuth flow does not complete before the expiration time.'

Suggested change
/// <exception cref="System.TimeoutException"/>
/// <exception cref="System.TimeoutException">Thrown when the OAuth flow does not complete before the expiration time.</exception>

Copilot uses AI. Check for mistakes.

Comment on lines +26 to +27
/// <exception cref="System.ArgumentNullException"></exception>
/// <exception cref="System.ArgumentException"></exception>
Copy link
Preview

Copilot AI May 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add context to this exception tag, e.g., 'Thrown when a required parameter is null.'

Suggested change
/// <exception cref="System.ArgumentNullException"></exception>
/// <exception cref="System.ArgumentException"></exception>
/// <exception cref="System.ArgumentNullException">Thrown when a required parameter, such as <paramref name="connections"/> or <paramref name="httpClientFactory"/>, is null.</exception>
/// <exception cref="System.ArgumentException">Thrown when an argument provided to the constructor is invalid.</exception>

Copilot uses AI. Check for mistakes.

@@ -37,7 +37,7 @@ public LocalArrayBufferWriter()
/// with an initial capacity specified.
/// </summary>
/// <param name="initialCapacity">The minimum capacity with which to initialize the underlying buffer.</param>
/// <exception cref="ArgumentException">
/// <exception cref="System.ArgumentException">
/// Thrown when <paramref name="initialCapacity"/> is not positive (i.e. less than or equal to 0).
Copy link
Preview

Copilot AI May 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Include a description of the invalid condition, e.g., 'Thrown when initialCapacity is less than or equal to zero.'

Suggested change
/// Thrown when <paramref name="initialCapacity"/> is not positive (i.e. less than or equal to 0).
/// Thrown when <paramref name="initialCapacity"/> is less than or equal to zero.

Copilot uses AI. Check for mistakes.

@phecke phecke added the documentation Improvements or additions to documentation label May 20, 2025
@phecke phecke closed this May 20, 2025
@phecke phecke deleted the api-desc branch May 20, 2025 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation ML: Core Tags changes to core libraries ML: Samples Tags changes to samples ML: Tests Tags changes to tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant