whatsinaname
Openapi to have XML documentation of the properties and endpoints.
I did create the context by generating from the assembly for all the types and I was able to build, but it is giving object null reference exception at below line
@martincostello - I did add context for all the types used in the assembly but it is giving me a null exception at below line
"method":"MartinCostello.OpenApi.Transformers.DescriptionsTransformer.TransformAsync"
@captainsafia - could you do needful here?
4 replies
Openapi to have XML documentation of the properties and endpoints.
I added services.AddHttpContextAccessor(); as well.
throwing object reference null exception.
at MartinCostello.OpenApi.Transformers.DescriptionsTransformer.TransformAsync(OpenApiOperation operation, OpenApiOperationTransformerContext context, CancellationToken cancellationToken)
at Microsoft.AspNetCore.OpenApi.OpenApiDocumentService.<GetOperationsAsync>d20.MoveNext()
at Microsoft.AspNetCore.OpenApi.OpenApiDocumentService.<GetOpenApiPathsAsync>d19.MoveNext()
at Microsoft.AspNetCore.OpenApi.OpenApiDocumentService.<GetOpenApiDocumentAsync>d12.MoveNext()
at Microsoft.AspNetCore.Builder.OpenApiEndpointRouteBuilderExtensions.<>cDisplayClass0_0.<<MapOpenApi>b0>d.MoveNext()
at Microsoft.AspNetCore.Http.Generated.<GeneratedRouteBuilderExtensions_g>F56B68D2B55B5B7B373BA2E4796D897848BC0F04A969B1AF6260183E8B9E0BAF2GeneratedRouteBuilderExtensionsCore.<>cDisplayClass2_0.<<MapGet0>gRequestHandler|5>d.MoveNext()
at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.<Invoke>d11.MoveNext()
at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.<Invoke>d6.MoveNext()
at Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddlewareImpl.<<Invoke>g__Awaited|10_0>d.MoveNext()
4 replies
β
Swashbuckle to other swagger UI
I tried using the openapi but it didn't work. below code is for reference
public void ConfigureServices(IServiceCollection services)
{
services.AddOpenApi();
}
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{
app.UseEndpoints(endpoints =>
{
endpoints.MapOpenApi(); endpoints.MapScalarApiReference(options => {
}); }); }
endpoints.MapOpenApi(); endpoints.MapScalarApiReference(options => {
}); }); }
7 replies
migrate to .NET 9
- update your visual studio 17.12.1
- If .NET9 SDK is not installed, then Download and Install .NET 9.0 from https://dotnet.microsoft.com/en-us/download
- Update the target framework
- Upgrade the NuGet packages
- Fix build errors if any.
- run the solution
- let it build and run as expected.
- try to push a docker to the local docker hub and run one of the APIs
6 replies
β
What is the free alternative to jet brains resharper ?
I totally agree with this. If we use resharper in vs, It is taking time to load everything and I feel the slowness. I spoke to one of the dev here and he suggested something to me but I missed it. He's from Canada, currently lives in the Philippines and suggested to me an extension that works better.
32 replies