Repository navigation
[release/17.0] Preserve ASPIRE010 and add ASPIRE013 for required CLI bundles - #22000
Mitch Denny (mitchdenny) wants to merge 1 commit into
Conversation
## Description Diagnostic IDs must keep their meaning across releases. #20867 changed ASPIRE010 from a suppressible warning about optional CLI bundle features into an unsuppressible error requiring the bundle. Existing suppression settings and the published diagnostic reference therefore describe a different contract. Restore ASPIRE010's original warning text, severity, and help link for non-C# AppHosts, where opting out remains supported. Introduce ASPIRE013 for the required-bundle error in C# AppHosts, without changing the C# bundle requirement or ASPIRE012 SDK-obsolescence warning. The two diagnostics are mutually exclusive. Update the product diagnostic list and migration guide, and cover enabled/disabled bundles, C#/non-C# applicability, both warning IDs in NoWarn, and the complete set of emitted Aspire diagnostics. Related documentation discussion: microsoft/aspire.dev#1880. That documentation PR should preserve the ASPIRE010 warning reference and document ASPIRE013 separately. Publishing the ASPIRE013 article and configuring https://aka.ms/aspire/diagnostics/aspire013 are coordinated documentation follow-ups; this product PR does not publish the site or configure the redirect. ### User-facing usage For a C# AppHost, this continues to fail the build, now with `error ASPIRE013` rather than a repurposed ASPIRE010: ```xml <PropertyGroup> <AspireUseCliBundle>false</AspireUseCliBundle> </PropertyGroup> ``` For a non-C# AppHost, opting out emits the original `warning ASPIRE010`, which remains suppressible with `<NoWarn>$(NoWarn);ASPIRE010</NoWarn>`. Adding either ASPIRE010 or ASPIRE013 to NoWarn does not bypass the C# requirement. ### Validation - `.\restore.cmd` — passed. - `dotnet build tests\Aspire.Hosting.Sdk.Tests\Aspire.Hosting.Sdk.Tests.csproj --no-restore --verbosity quiet` — passed, with four NU1902/NU1903 audit warnings for System.Security.Cryptography.Pkcs 10.0.12. No dependency versions are changed by this PR. - Native Microsoft.Testing.Platform execution — passed, 14/14 tests: ```powershell & .\artifacts\bin\Aspire.Hosting.Sdk.Tests\Debug\net10.0\Aspire.Hosting.Sdk.Tests.exe --filter-method "*.CliBundleDiagnosticsRespectLanguageAndWarningSuppression" --filter-method "*.AppHostSdkEmitsObsoleteWarning" --filter-method "*.AppHostSdkObsoleteWarningCanBeSuppressed" --filter-method "*.MinimumSdkVersionErrorDoesNotFireForNonSdkAppHost" --filter-method "*.ComputeRunArgumentsDoesNotUseAspireCliWhenCliBundleIsDisabled" --filter-not-trait "quarantined=true" --filter-not-trait "outerloop=true" ``` - `git diff --check` — passed. - The initial `dotnet test` invocation below built the project but timed out in a child MSBuild invocation and was stopped. Retrying the diagnostic matrix with NuGet audit disabled also timed out and was stopped. Running the same selected tests with the built native MTP executable succeeded as recorded above. ```powershell dotnet test --project tests\Aspire.Hosting.Sdk.Tests\Aspire.Hosting.Sdk.Tests.csproj --no-launch-profile -- --filter-method "*.CliBundleDiagnosticsRespectLanguageAndWarningSuppression" --filter-method "*.AppHostSdkEmitsObsoleteWarning" --filter-method "*.AppHostSdkObsoleteWarningCanBeSuppressed" --filter-method "*.MinimumSdkVersionErrorDoesNotFireForNonSdkAppHost" --filter-method "*.ComputeRunArgumentsDoesNotUseAspireCliWhenCliBundleIsDisabled" --filter-not-trait "quarantined=true" --filter-not-trait "outerloop=true" ``` Full solution and cross-platform validation were not run locally. Fixes # (issue) ## Checklist - Is this feature complete? - [x] Yes. Ready to ship. - [ ] No. Follow-up changes expected. - Are you including unit tests for the changes and scenario tests if relevant? - [x] Yes - [ ] No - Did you add public API? - [ ] Yes - If yes, did you have an API Review for it? - [ ] Yes - [ ] No - Did you add `<remarks />` and `<code />` elements on your triple slash comments? - [ ] Yes - [ ] No - [x] No - Does the change make any security assumptions or guarantees? - [ ] Yes - If yes, have you done a threat model and had a security review? - [ ] Yes - [ ] No - [x] No --------- Co-authored-by: David Pine <7679720+IEvangelist@users.noreply.github.com> Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> (cherry picked from commit ba43a21)
Tests selector45 / 101 PR test projects · 3 PR jobs, from 3 changed files. Selected PR test projects (45 / 101)
Selected PR jobs (3)
How these were chosen — grouped by what changed
🔧 show 43
📦 affected project 🧪 🧪 Job reasons
Selection computed for commit |
|
Approved for inclusion in release/17.0. Do not merge yet. |
|
Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt. |
|
Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt. |
|
Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt. |
|
Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt. |
|
Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt. |
|
Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt. |
…bundles (#22106) Backport of #21288 to release/17.0 /cc @IEvangelist ## Description Standalone backport preserving ASPIRE010 diagnostic compatibility and introducing ASPIRE013 for required CLI bundles. Targets `release/17.0` directly; the old chained backport #22000 is left untouched. ## Checklist - Is this feature complete? - [x] Yes. Ready to ship. - [ ] No. Follow-up changes expected. - Are you including unit tests for the changes and scenario tests if relevant? - [x] Yes - [ ] No - Did you add public API? - [ ] Yes - If yes, did you have an API Review for it? - [ ] Yes - [ ] No - Did you add `<remarks />` and `<code />` elements on your triple slash comments? - [ ] Yes - [ ] No - [x] No - Does the change make any security assumptions or guarantees? - [ ] Yes - If yes, have you done a threat model and had a security review? - [ ] Yes - [ ] No - [x] No ## Customer Impact Restores the suppressible ASPIRE010 warning for non-C# AppHosts while retaining the required C# bundle error under ASPIRE013. Existing suppression settings and published ASPIRE010 guidance regain their original meaning; the C# bundle requirement is unchanged. ## Testing Backport verification: the aggregate diff has the same stable patch ID as merged source commit `ba43a210a8c6d202891f71d86dd100f54d60fa88`: `d3d4606d4b3679de5956ce9919a04a0d56e23577`. The PR targets `release/17.0` directly and has no native stack membership. Source-PR validation, not rerun locally on this backport: ```powershell dotnet build tests\Aspire.Hosting.Sdk.Tests\Aspire.Hosting.Sdk.Tests.csproj --no-restore --verbosity quiet ``` Passed, with four NU1902/NU1903 audit warnings for the pinned System.Security.Cryptography.Pkcs dependency. ```powershell & .\artifacts\bin\Aspire.Hosting.Sdk.Tests\Debug\net10.0\Aspire.Hosting.Sdk.Tests.exe --filter-method "*.CliBundleDiagnosticsRespectLanguageAndWarningSuppression" --filter-method "*.AppHostSdkEmitsObsoleteWarning" --filter-method "*.AppHostSdkObsoleteWarningCanBeSuppressed" --filter-method "*.MinimumSdkVersionErrorDoesNotFireForNonSdkAppHost" --filter-method "*.ComputeRunArgumentsDoesNotUseAspireCliWhenCliBundleIsDisabled" --filter-not-trait "quarantined=true" --filter-not-trait "outerloop=true" ``` Passed: 14/14 selected native MTP tests. The source PR separately discloses earlier timed-out `dotnet test` attempts; they are not counted as passes. No local release-branch tests were rerun. Release-branch CI was pending when this section was written; this is not a claim that backport CI has passed. ## Risk Low. Localized diagnostic compatibility fix; it does not relax or change the C# CLI-bundle requirement. ## Regression? Yes. #20867 repurposed ASPIRE010 from its original suppressible warning contract. --------- Co-authored-by: David Pine <7679720+IEvangelist@users.noreply.github.com> Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Description
Backport of #21288 to
release/17.0(cherry-picked from ba43a21 with no modifications). Layer 3 of 55 in the release/17.0 backport stack; stacked on #21999.Backport recommendation: Yes — Diagnostic IDs must be correct before ship; 17.0 milestone.
Backport of #21288
Checklist
<remarks />and<code />elements on your triple slash comments?