Hide staging channel from aspire update --self when feature flag is disabled#14675
Merged
Hide staging channel from aspire update --self when feature flag is disabled#14675
aspire update --self when feature flag is disabled#14675Conversation
…isabled When the stagingChannelEnabled feature flag is not set, the staging channel is now excluded from the channel selection prompt in `aspire update --self`. Previously, staging was always shown regardless of the feature flag, which caused failures when users selected it. Co-authored-by: davidfowl <95136+davidfowl@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix staging option in aspire update command
Hide staging channel from Feb 25, 2026
aspire update --self when feature flag is disabled
Contributor
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 14675Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 14675" |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes aspire update --self so that the interactive channel selection prompt only offers the staging channel when the stagingChannelEnabled feature flag is enabled, preventing users from selecting an unavailable channel.
Changes:
- Gate the self-update prompt’s channel list on
KnownFeatures.StagingChannelEnabled. - Add unit tests covering both “staging enabled” and “staging disabled” prompt behavior.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/Aspire.Cli/Commands/UpdateCommand.cs | Conditionally includes staging in the self-update channel selection prompt based on the feature flag. |
| tests/Aspire.Cli.Tests/Commands/UpdateCommandTests.cs | Adds tests asserting the prompt includes/excludes staging depending on whether the feature is enabled. |
adamint
approved these changes
Feb 25, 2026
Contributor
|
/backport to release/13.2 |
Contributor
|
Started backporting to release/13.2: https://github.com/dotnet/aspire/actions/runs/22749767187 |
Merged
10 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
aspire update --selfunconditionally offered "staging" in the channel selection prompt, regardless of thestagingChannelEnabledfeature flag. Selecting it without the flag would fail since no staging channel exists.The fix checks
_features.IsFeatureEnabled(KnownFeatures.StagingChannelEnabled)before including staging in the prompt choices — consistent with how the channel option description andPackagingService.GetChannelsAsyncalready gate on this flag.Checklist
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.