Skip to content

Conversation

@captainsafia
Copy link
Member

  • Consume changes to add native AoT-compat back to to the library
  • Consume changes to fix OpenAPI tag references in operations
  • React to changes in Serialize APIs

@captainsafia captainsafia requested review from a team and wtgodbe as code owners January 22, 2025 20:04
@ghost ghost added the area-infrastructure Includes: MSBuild projects/targets, build scripts, CI, Installers and shared framework label Jan 22, 2025
var document = await targetDocumentService.GetOpenApiDocumentAsync(scopedService.ServiceProvider);
var jsonWriter = new OpenApiJsonWriter(writer);
document.Serialize(jsonWriter, openApiSpecVersion);
await document.SerializeAsync(jsonWriter, openApiSpecVersion);
Copy link
Member

Choose a reason for hiding this comment

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

Should we be flowing a cancellation token from somewhere? Looks like this might only be for the command line tool so it's fine?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah, for this particular codepath, we don't have a CancellationToken to pass through to this API. We could probably consider adding one for the interface overall as part of #58353 but it's not feasible at the moment.

@captainsafia captainsafia requested a review from Copilot January 22, 2025 21:59
Copy link
Contributor

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.

Copilot reviewed 5 out of 14 changed files in this pull request and generated 1 comment.

Files not reviewed (9)
  • eng/Versions.props: Language not supported
  • eng/testing/linker/project.csproj.template: Language not supported
  • src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Integration/snapshots/OpenApiDocumentIntegrationTests.VerifyOpenApiDocument_documentName=controllers.verified.txt: Language not supported
  • src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Integration/snapshots/OpenApiDocumentIntegrationTests.VerifyOpenApiDocument_documentName=forms.verified.txt: Language not supported
  • src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Integration/snapshots/OpenApiDocumentIntegrationTests.VerifyOpenApiDocument_documentName=responses.verified.txt: Language not supported
  • src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Integration/snapshots/OpenApiDocumentIntegrationTests.VerifyOpenApiDocument_documentName=schemas-by-ref.verified.txt: Language not supported
  • src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Integration/snapshots/OpenApiDocumentIntegrationTests.VerifyOpenApiDocument_documentName=v1.verified.txt: Language not supported
  • src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Integration/snapshots/OpenApiDocumentIntegrationTests.VerifyOpenApiDocument_documentName=v2.verified.txt: Language not supported
  • src/Tools/GetDocumentInsider/tests/GetDocumentTests.cs: Evaluated as low risk
Comments suppressed due to low confidence (1)

src/OpenApi/src/Services/OpenApiDocumentService.cs:63

  • [nitpick] Consider using Array.Empty() instead of []. This is more explicit and improves readability.
var schemaTransformers = _options.SchemaTransformers.Count > 0 ? new IOpenApiSchemaTransformer[_options.SchemaTransformers.Count] : [];

…penApiDocumentService/OpenApiDocumentServiceTests.Operations.cs
…penApiDocumentService/OpenApiDocumentServiceTests.Operations.cs

Co-authored-by: Brennan <[email protected]>
@captainsafia captainsafia merged commit aa38ac3 into main Jan 23, 2025
27 checks passed
@captainsafia captainsafia deleted the openapi-v2-preview5 branch January 23, 2025 02:21
@dotnet-policy-service dotnet-policy-service bot added this to the 10.0-preview1 milestone Jan 23, 2025
captainsafia added a commit that referenced this pull request Feb 11, 2025
* Update to Microsoft.OpenApi v2.0.0-preview5

* Address feedback

* Update src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Services/OpenApiDocumentService/OpenApiDocumentServiceTests.Operations.cs

* Update src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Services/OpenApiDocumentService/OpenApiDocumentServiceTests.Operations.cs

Co-authored-by: Brennan <[email protected]>

---------

Co-authored-by: Brennan <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-infrastructure Includes: MSBuild projects/targets, build scripts, CI, Installers and shared framework

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants