argoproj/argo-workflows · warning

unable to parse output parameter set request: %w

Error message

unable to parse output parameter set request: %w

What it means

After parsing NAME=VALUE pairs into a map[string]string, the CLI serializes them to JSON with json.Marshal before sending a SetWorkflow request. json.Marshal on a map[string]string essentially never fails (even odd strings are escaped), so this error is effectively unreachable in practice, but it is wrapped with %w so any future marshal failure is reported this way.

Source

Thrown at cmd/argo/commands/node.go:59

			}

			outputParameters := ""
			if len(setArgs.outputParameters) > 0 {
				outputParams := make(map[string]string)
				for _, param := range setArgs.outputParameters {
					parts := strings.SplitN(param, "=", 2)
					if len(parts) != 2 {
						return fmt.Errorf("expected parameter of the form: NAME=VALUE. Received: %s", param)
					}
					unquoted, err := strconv.Unquote(parts[1])
					if err != nil {
						unquoted = parts[1]
					}
					outputParams[parts[0]] = unquoted
				}
				res, err := json.Marshal(outputParams)
				if err != nil {
					return fmt.Errorf("unable to parse output parameter set request: %w", err)
				}
				outputParameters = string(res)
			}

			ctx := cmd.Context()
			ctx, apiClient, err := client.NewAPIClient(ctx)
			if err != nil {
				return err
			}
			serviceClient := apiClient.NewWorkflowServiceClient(ctx)
			namespace := client.Namespace(ctx)

			selector, err := fields.ParseSelector(setArgs.nodeFieldSelector)
			if err != nil {
				return fmt.Errorf("unable to parse node field selector '%s': %w", setArgs.nodeFieldSelector, err)
			}

			_, err = serviceClient.SetWorkflow(ctx, &workflowpkg.WorkflowSetRequest{

View on GitHub (pinned to 35bff19146)

Solutions

  1. Reinstall/upgrade the argo CLI to a stock binary.
  2. Check for unsupported characters by simplifying the --output-parameter values.
  3. Report to argo-workflows if reproducible with an official release.
Defensive patterns

Strategy: try-catch

Try / catch

if err := cmd.Run(); err != nil {
    var wrapped interface{ Unwrap() error }
    if errors.As(err, &target) && strings.Contains(err.Error(), "unable to parse output parameter set request") {
        // retry or report marshal failure
    }
}

Prevention

When it happens

Trigger: Theoretically, a failure of json.Marshal(outputParams) while building the output-parameters payload of `argo node set --output-parameter`.

Common situations: In practice never observed by users; map[string]string marshaling cannot fail with the current code. If seen, it indicates a corrupted or modified binary.

Understand the failure class

Background: "JSON serialization failed", "not JSON serializable", "Failed to serialize": why JSON marshaling errors happen and how to fix them — this error's family across 46 libraries.

Related errors


AI-assisted analysis of argoproj/argo-workflows@35bff19146 (2026-09-03). Data as JSON: /api/errors/7bcee39a1e02ce3a. Report an issue: GitHub.