Azure / azure-functions-openapi-extension

This extension provides an Azure Functions app with Open API capability for better discoverability to consuming parties
https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.OpenApi/
MIT License
375 stars 196 forks source link

Compiler errors with Isolated .Net Framework 4.8 #575

Open AlienDave opened 1 year ago

AlienDave commented 1 year ago

Error CS0246: The type or namespace name 'OpenApiOperation' could not be found (are you missing a using directive or an assembly reference?)

I'm writing a v4 Isolated function, using .Net Framework 4.8.

I have using Microsoft.Azure.Functions.Worker.Extensions.OpenApi.Extensions; (I've tried also without .Extensions) Intellicode only suggests using Microsoft.Azure.Webjobs...

Screenshots

image

image

Environment (please complete the following information, if applicable):

newportg commented 10 months ago

I have sort of the same issue. I create a vanilla Azure Function V4 Framework 4.8 default application and only added the Microsoft.Azure.Functions.Worker.Extensions.OpenApi library. If I run the code and call the http://localhost:7112/api/swagger/ui url i get

image

in the console.

image

returned to the browser