From c2f2753051b69df551fc4c65bfc264d16d855a86 Mon Sep 17 00:00:00 2001 From: Josh Ward <55707591+joshuajtward@users.noreply.github.com> Date: Thu, 13 Jun 2024 09:23:33 +0100 Subject: [PATCH] add comment to call out potentially brittle use of workflowShared --- pkg/cmd/run/list/list.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkg/cmd/run/list/list.go b/pkg/cmd/run/list/list.go index 39487983e..9f4c71132 100644 --- a/pkg/cmd/run/list/list.go +++ b/pkg/cmd/run/list/list.go @@ -120,8 +120,11 @@ func listRun(opts *ListOptions) error { opts.IO.StartProgressIndicator() if opts.WorkflowSelector != "" { + // initially the workflow state is limited to 'active' states := []workflowShared.WorkflowState{workflowShared.Active} if opts.All { + // the all flag tells us to add the remaining workflow states + // note: this will be incomplete if more workflow states are added to `workflowShared` states = append(states, workflowShared.DisabledManually, workflowShared.DisabledInactivity) } if workflow, err := workflowShared.ResolveWorkflow(