-
Notifications
You must be signed in to change notification settings - Fork 526
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 9.1 templates #7229
base: main
Are you sure you want to change the base?
Add 9.1 templates #7229
Conversation
This seems like it goes against our support policy, doesn't it? We don't support 9.0 anymore after we ship 9.1. So why should we continue to have 9.0 templates, if we no longer support it? |
Yes, but it's a huge inconvenience given all the trade-offs we made WRT our approach to template packaging for Aspire. If we remove 9.0 (or 8.2) from the package in the 9.1 update, you can no longer perform Aspire project creation or scaffolding operations in VS or VS Code for 9.0 projects. I can't think of anywhere else in our wider .NET experience where we instantly remove the ability to work with unsupported versions when the new version is released, because doing so would be hugely disruptive. The other advantage of this approach is it makes dogfooding much easier as you can install the daily 9.1 templates package (or even a locally built version) and still work with 9.0 projects/solutions with no issue. |
As @DamianEdwards has shared in the past, one thing is not supporting it, and a different one is blocking people from using it. One good precedent is the newer SDKs, they allow you to compile assemblies and applications that target out of support framework, while of course warning you that those runtimes are out of support. I think that the change here is following that same pattern, which seems good to me. |
What happens in .NET Aspire 10? We drop |
@eerhardt undecided, that's something we figure out for 10. My guess is we drop 8.x and everything but the last 9.x |
Just realized this needs another fix to allow picking the Aspire version when targeting net9.0 so this isn't ready to go just yet. |
@@ -21,7 +21,8 @@ | |||
"type": "solution", | |||
"editorTreatAs": "solution", | |||
"aspire-8.2-tfms": "net8.0", | |||
"aspire-9.0-tfms": "net8.0;net9.0" | |||
"aspire-9.0-tfms": "net8.0;net9.0", |
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.
Just out of curiosity (not super familiar with these files) how come these tags aren't in all template configs? For instance, aspire-apphost doesn't seem to have this change. Is that intentional?
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.
they're only used by the code in VS that drives the solution explorer "Add Aspire orchestration" context menu.
@@ -10,8 +10,8 @@ | |||
<ItemGroup> | |||
<FrameworkReference Include="Microsoft.AspNetCore.App" /> | |||
|
|||
<PackageReference Include="Microsoft.Extensions.Http.Resilience" Version="!!REPLACE_WITH_DOTNET_EXTENSIONS_VERSION!!" /> | |||
<PackageReference Include="Microsoft.Extensions.ServiceDiscovery" Version="!!REPLACE_WITH_LATEST_VERSION!!" /> | |||
<PackageReference Include="Microsoft.Extensions.Http.Resilience" Version="9.1.0" /> |
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.
NIT: Should this remain being bumped?
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.
No, we don't update the 9.0 templates from this point on
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.
Left a copule of small comments, but this looks good otherwise. Thank you so much for getting this work done @DamianEdwards
], | ||
"defaultValue": "9.1" | ||
}, | ||
"AspireVersionNet8": { | ||
"type": "parameter", | ||
"description": "The version of .NET Aspire to use.", | ||
"displayName": ".NET Aspire version", | ||
"datatype": "choice", | ||
"isEnabled": "Framework == net8.0", |
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.
I think you can remove the AspireVersionCli
symbol entirely if you loosen this enablement condition to allow Framework
to be either net8.0
or net9.0
. I think this is why --framework net9.0 --aspire-version 9.0
doesn't actually impact the aspire version to be used.
Description
Adds 9.1 templates to the template package as the default. The 9.0 templates got updated to use fixed package versions. The 8.2 and 9.0 templates remain in the package as that's our current side-by-side strategy (all template versions in one package) until we get to 10.0 at which point we can decide which versions to drop from the package.
Fixes #7160
Checklist
Screenshot of Aspire version option in VS:
Screenshot of Aspire version option in C# Dev Kit: