Skip to content
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

[REQ] Will the 5.0 final release include a server-stub generator for C# .NET 5? #8017

Closed
KenCollins-Skkynet opened this issue Nov 24, 2020 · 6 comments · Fixed by #8717
Closed

Comments

@KenCollins-Skkynet
Copy link

The current 'aspnetcore' generator is not compatible with .NET 5. Specifically, the definition of the Filter 'Apply' method now expects an OpenApiDocument instead of a SwaggerDocument. I'm sure there are other improvements that can be added. Nonetheless, it would be nice to have a C# ASP.NET Core .NET 5 server-stub generator. Of course, I know I can create a custom template, but I'd rather not go down that path if something is already in work. Thanks.

@wing328
Copy link
Member

wing328 commented Nov 25, 2020

We want to make the aspnetcore generator compatible with .NET 5

	aspnetCoreVersion
	    ASP.NET Core version: 3.1, 3.0, 2.2, 2.1, 2.0 (deprecated) (Default: 2.2)

Is that something you can help with? I can show you some good starting points to begin with.

@KenCollins-Skkynet
Copy link
Author

Hi William.

I was hoping someone else had already done the work.
:-)

Sorry, I cannot commit; however, if I decide to create a custom template for my own project, I’ll consider contributing that solution. My priority is my current project.

@wing328
Copy link
Member

wing328 commented Nov 26, 2020

No problem. Let's wait to see if someone from the community has the time to make the contributions.

Of course, you're welcome to sponsor the enhancement to make it a higher priority :)

@KenCollins-Skkynet
Copy link
Author

KenCollins-Skkynet commented Nov 26, 2020 via email

@etherealjoy
Copy link
Contributor

etherealjoy commented Dec 13, 2020

@KenCollins-Skkynet
To make it work with .NET 5 you have to select the framework version. Default .NET Core framework in the tool is 2.2 which is not compatible with .NET 5.
Try
--additional-properties aspnetCoreVersion=3.0
.NET Core 3.1 is compatible with .NET 5

@KenCollins-Skkynet
Copy link
Author

KenCollins-Skkynet commented Dec 13, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants