From 5cec45457bc6336d6c113f4d8d921f33589ad6ea Mon Sep 17 00:00:00 2001 From: "flamingo[bot]" <277372822+flamingo[bot]@users.noreply.github.com> Date: Mon, 7 Sep 2026 05:07:39 +0000 Subject: [PATCH 1/2] fix(OPENFRAM-004): 3 review findings across 2 files --- cmd/app/upgrade.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cmd/app/upgrade.go b/cmd/app/upgrade.go index 294fdbe5..615100f9 100644 --- a/cmd/app/upgrade.go +++ b/cmd/app/upgrade.go @@ -58,11 +58,11 @@ Examples: // runUpgradeCommand dispatches to change-ref (Mode 1) or force-sync (Mode 2). func runUpgradeCommand(cmd *cobra.Command, args []string) error { + verbose := getVerboseFlag(cmd) flags, err := extractInstallFlags(cmd) if err != nil { - return err + return sharedErrors.HandleGlobalError(err, verbose) } - verbose := getVerboseFlag(cmd) sync, _ := cmd.Flags().GetBool("sync") refChanged := cmd.Flags().Changed("ref") @@ -70,7 +70,7 @@ func runUpgradeCommand(cmd *cobra.Command, args []string) error { // force-sync the CURRENT ref and discard an explicit --ref — the user // believed they had deployed the new version (audit F5/T1-9). if refChanged && sync { - return fmt.Errorf("--ref and --sync are mutually exclusive: --ref deploys a new ref (Mode 1), --sync re-syncs the current ref (Mode 2); drop one of them") + return sharedErrors.HandleGlobalError(fmt.Errorf("--ref and --sync are mutually exclusive: --ref deploys a new ref (Mode 1), --sync re-syncs the current ref (Mode 2); drop one of them"), verbose) } if upgradeIsChangeRef(refChanged, sync) { From 09ee762de78958e0b1c13525b50642c5c7813354 Mon Sep 17 00:00:00 2001 From: "flamingo[bot]" <277372822+flamingo[bot]@users.noreply.github.com> Date: Mon, 7 Sep 2026 05:07:40 +0000 Subject: [PATCH 2/2] fix(OPENFRAM-004): 3 review findings across 2 files --- cmd/app/status.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/app/status.go b/cmd/app/status.go index f907b463..98e78ffa 100644 --- a/cmd/app/status.go +++ b/cmd/app/status.go @@ -49,10 +49,10 @@ func runStatusCommand(cmd *cobra.Command, _ []string) error { return sharedErrors.HandleGlobalError(err, verbose) } if (watch || interactive) && format != "text" { - return fmt.Errorf("--watch/--interactive are live terminal views and cannot combine with --output %s", format) + return sharedErrors.HandleGlobalError(fmt.Errorf("--watch/--interactive are live terminal views and cannot combine with --output %s", format), verbose) } if (watch || interactive) && (!ui.IsTerminal() || ui.IsPlain()) { - return fmt.Errorf("--watch/--interactive need an interactive terminal (and cannot combine with --plain)") + return sharedErrors.HandleGlobalError(fmt.Errorf("--watch/--interactive need an interactive terminal (and cannot combine with --plain)"), verbose) } cfg, err := resolveRestConfig(contextName)