-
Notifications
You must be signed in to change notification settings - Fork 702
Put DeployCommand behind a feature flag #10613
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
Conversation
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.
Pull Request Overview
This PR implements feature flag gating for the DeployCommand in the Aspire CLI. The deploy command is now hidden behind a feature flag (deployCommandEnabled
) that defaults to false, preventing users from accessing the command until a built-in deployer is available.
- Added a new feature flag
DeployCommandEnabled
to control deploy command visibility - Updated RootCommand to conditionally add the deploy command based on the feature flag
- Modified all existing deploy command tests to enable the feature flag
- Added new tests to verify the feature flag behavior
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
File | Description |
---|---|
src/Aspire.Cli/KnownFeatures.cs | Added DeployCommandEnabled feature flag constant |
src/Aspire.Cli/Commands/RootCommand.cs | Added conditional logic to only register deploy command when feature flag is enabled |
tests/Aspire.Cli.Tests/Commands/DeployCommandTests.cs | Updated all test methods to enable the feature flag and added tests for feature flag behavior |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@joperezr @mitchdenny Can I get reviews/help merging this in? |
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
/backport to release/9.4 |
Started backporting to release/9.4: https://github.com/dotnet/aspire/actions/runs/16460221301 |
@mitchdenny backporting to "release/9.4" failed, the patch most likely resulted in conflicts: $ git am --3way --empty=keep --ignore-whitespace --keep-non-patch changes.patch
Applying: Put DeployCommand behind a feature flag
Using index info to reconstruct a base tree...
M src/Aspire.Cli/Commands/RootCommand.cs
M src/Aspire.Cli/KnownFeatures.cs
M tests/Aspire.Cli.Tests/Commands/DeployCommandTests.cs
Falling back to patching base and 3-way merge...
Auto-merging tests/Aspire.Cli.Tests/Commands/DeployCommandTests.cs
CONFLICT (content): Merge conflict in tests/Aspire.Cli.Tests/Commands/DeployCommandTests.cs
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config set advice.mergeConflict false"
Patch failed at 0001 Put DeployCommand behind a feature flag
Error: The process '/usr/bin/git' failed with exit code 128 Please backport manually! |
@mitchdenny this is in 9.4 only. |
Yeah just realized. I was looking at main thinking - why isn't that PR there :) |
Put the DeployCommand behind a feature flag until a built-in deployer is available.