-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add net8.0 target framework #4502
Conversation
Would be great if you could update it against latest master |
I'd say the build project can stay on .net 7 for now, just the needed libraries etc need to be updated for now. |
@RicoSuter @lahma done |
nit: if you look at the GitHub diff, you can see that there are multiple odd indents present, maybe tabs vs spaces or something? |
@RicoSuter @lahma can you please approve the latest workflow? |
@lahma
Any other suggestions? |
IMO it's a good idea to add them, NUKE setup was cleaned earlier to not include obsolete ones bur for NET 8 is a different story. Getting builds out against RC would help to validate and find possible problems. |
@lahma done, we can give it another try |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
I found one place that might still need alteration: NSwag/src/NSwag.Commands/Commands/Generation/AspNetCore/AspNetCoreToOpenApiCommand.cs Lines 146 to 148 in c24ed12
Because it's under pre-processor directive which should only hit modern .NET I wonder whether the |
I think we can remove this if completely |
@@ -40,7 +40,7 @@ public async Task Invoke(HttpContext context) | |||
|
|||
var suffix = !string.IsNullOrWhiteSpace(_swaggerRoute) ? "?url=" + _transformToExternal(_swaggerRoute, context.Request) : ""; | |||
var path = _transformToExternal(_swaggerUiRoute, context.Request); | |||
context.Response.Headers.Add("Location", (path != "/" ? path : "") + "/index.html" + suffix); | |||
context.Response.Headers.Append("Location", (path != "/" ? path : "") + "/index.html" + suffix); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you have a problem with the Add()?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VS preview complains with https://learn.microsoft.com/en-us/aspnet/core/diagnostics/asp0019?view=aspnetcore-8.0
I think the whole reasoning behind the two ifs (.netframework, .netcore) is that you get a "nice" error when you try to load a .netfw project in .net core and vice versa, which you would not get anymore (probably it fails differently now :)) |
... updated with my proposal (keep ifs to be more safe but make it more generic in .net "core" case so we do not have to touch it again) - it's anway just a "small" safe guard. |
* Add net8.0 target framework * Install net8 sdk missing from base image * Remove unnecessary TargetFramework conditions * Update AspNetCoreToOpenApiCommand.cs --------- Co-authored-by: Rico Suter <mail@rsuter.com>
// Will update as soon as .net 8 gets a stable release
// Need to update Nuke.Common to support net8 nuke-build/nuke#1247