From 7c40eeff467966b825d25f79c8d84b712159c342 Mon Sep 17 00:00:00 2001 From: iliya Date: Tue, 17 Nov 2026 05:08:29 +0200 Subject: [PATCH] fix(ci): refresh the deactivation goldens and lower the update command's complexity --- .../agentpluginscli/lifecycle_commands.go | 17 ++++++++++++----- .../testdata/golden/deactivate_confirmed.json | 17 +++++++++++++++++ .../golden/deactivate_recorded_ownership.json | 17 +++++++++++++++++ .../testdata/golden/deactivate_unconfirmed.json | 17 +++++++++++++++++ 4 files changed, 63 insertions(+), 5 deletions(-) diff --git a/cli/internal/agentpluginscli/lifecycle_commands.go b/cli/internal/agentpluginscli/lifecycle_commands.go index b885b6ff21..6a8dccd326 100644 --- a/cli/internal/agentpluginscli/lifecycle_commands.go +++ b/cli/internal/agentpluginscli/lifecycle_commands.go @@ -28,11 +28,8 @@ func newUpdateCommand(app App, opts *options) *cobra.Command { operationApp := app operationApp.Lifecycle.PrepareHostsForPreview = !opts.dryRun if all { - if len(args) > 0 { - return fmt.Errorf("choose either one installation or --all") - } - if strings.TrimSpace(opts.target) != "" { - return fmt.Errorf("--target cannot be combined with --all; every installation keeps its recorded targets") + if err := validateUpdateAll(args, opts); err != nil { + return err } return runUpdateAllRetryable(cmd, operationApp, opts) } @@ -62,6 +59,16 @@ func newUpdateCommand(app App, opts *options) *cobra.Command { return command } +func validateUpdateAll(args []string, opts *options) error { + if len(args) > 0 { + return fmt.Errorf("choose either one installation or --all") + } + if strings.TrimSpace(opts.target) != "" { + return fmt.Errorf("--target cannot be combined with --all; every installation keeps its recorded targets") + } + return nil +} + func newRepairCommand(app App, opts *options) *cobra.Command { command := &cobra.Command{ Use: "repair ", Short: "Explicitly restore a missing or modified managed package", diff --git a/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_confirmed.json b/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_confirmed.json index 8523f61bde..34332bdbe1 100644 --- a/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_confirmed.json +++ b/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_confirmed.json @@ -8,6 +8,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "unchanged", + "SettledPartialRemoval": false, "UserActions": [ "Reload Antigravity to clear the plugin from a running session" ] @@ -22,6 +23,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "uninstall the plugin in ChatGPT Plugins, then rerun remove with `--external-uninstalled` (also use the flag if it was never activated)" ] @@ -43,6 +45,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -55,6 +58,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove any Cline skills and MCP entries for this plugin, then rerun remove with `--external-uninstalled` (also use the flag if it was never activated)" ] @@ -83,6 +87,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -109,6 +114,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -121,6 +127,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -133,6 +140,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -152,6 +160,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -164,6 +173,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -176,6 +186,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "Run /reload or /new in Kimi Code to load the installed plugin; runtime MCP connections and authentication have not been verified." ] @@ -190,6 +201,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove the legacy custom Power in Kiro, then rerun remove with `--external-uninstalled`" ] @@ -204,6 +216,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -216,6 +229,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -237,6 +251,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -263,6 +278,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -275,6 +291,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove the prepared package manually, then rerun remove with `--external-uninstalled`" ] diff --git a/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_recorded_ownership.json b/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_recorded_ownership.json index 41af08bf45..5d0321649d 100644 --- a/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_recorded_ownership.json +++ b/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_recorded_ownership.json @@ -8,6 +8,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "unchanged", + "SettledPartialRemoval": false, "UserActions": [ "Reload Antigravity to clear the plugin from a running session" ] @@ -22,6 +23,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "uninstall the plugin in ChatGPT Plugins, then rerun remove with `--external-uninstalled` (also use the flag if it was never activated)" ] @@ -43,6 +45,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -55,6 +58,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -81,6 +85,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -107,6 +112,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -119,6 +125,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -131,6 +138,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -163,6 +171,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -175,6 +184,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -187,6 +197,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "Run /reload or /new in Kimi Code to load the installed plugin; runtime MCP connections and authentication have not been verified." ] @@ -201,6 +212,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove the legacy custom Power in Kiro, then rerun remove with `--external-uninstalled`" ] @@ -215,6 +227,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -227,6 +240,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -266,6 +280,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -292,6 +307,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -304,6 +320,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove the prepared package manually, then rerun remove with `--external-uninstalled`" ] diff --git a/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_unconfirmed.json b/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_unconfirmed.json index ae6c561c0a..8b419eb926 100644 --- a/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_unconfirmed.json +++ b/install/integrationctl/agentplugins/providers/testdata/golden/deactivate_unconfirmed.json @@ -8,6 +8,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "Only the exact UAP-owned Antigravity plugin directory may be removed" ] @@ -22,6 +23,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "uninstall the plugin in ChatGPT Plugins, then rerun remove with `--external-uninstalled` (also use the flag if it was never activated)" ] @@ -36,6 +38,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "agentplugins will verify and remove its managed Claude Code @skills-dir plugin" ] @@ -50,6 +53,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove any Cline skills and MCP entries for this plugin, then rerun remove with `--external-uninstalled` (also use the flag if it was never activated)" ] @@ -64,6 +68,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -76,6 +81,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "agentplugins will uninstall the plugin from GitHub Copilot CLI and VS Code automatically" ] @@ -90,6 +96,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -102,6 +109,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "agentplugins will remove its managed Gemini CLI skills and MCP entries automatically" ] @@ -116,6 +124,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "agentplugins will uninstall the managed Grok Build plugin automatically" ] @@ -130,6 +139,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -142,6 +152,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -154,6 +165,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove the legacy custom Power in Kiro, then rerun remove with `--external-uninstalled`" ] @@ -168,6 +180,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "agentplugins will remove its managed OpenCode skills and MCP entries automatically" ] @@ -182,6 +195,7 @@ "ExternalRemovalComplete": true, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": null } }, @@ -194,6 +208,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "agentplugins will uninstall the managed Qoder plugin automatically" ] @@ -208,6 +223,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "agentplugins will uninstall the plugin from GitHub Copilot CLI and VS Code automatically" ] @@ -222,6 +238,7 @@ "ExternalRemovalComplete": false, "LocalActions": null, "NativeEffect": "", + "SettledPartialRemoval": false, "UserActions": [ "remove the prepared package manually, then rerun remove with `--external-uninstalled`" ]