doc(run list): add enterprise ruleset notes

Co-authored-by: Andy Feller <andyfeller@github.com>
This commit is contained in:
Kynan Ware 2025-03-24 14:04:16 -06:00 committed by GitHub
parent a35ae3b8bb
commit 30960d59bc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 3 deletions

View file

@ -63,8 +63,7 @@ func NewCmdList(f *cmdutil.Factory, runF func(*ListOptions) error) *cobra.Comman
Note that providing the %[1]sworkflow_name%[1]s to the %[1]s-w%[1]s flag will not fetch disabled workflows.
Also pass the %[1]s-a%[1]s flag to fetch disabled workflow runs using the %[1]sworkflow_name%[1]s and the %[1]s-w%[1]s flag.
A run with no workflow name indicates that the run likely belongs an organization ruleset required workflow,
and the authenticated user does not have access to the workflow definition.
Runs created by organization and enterprise ruleset workflows will not display a workflow name due to GitHub API limitations.
`, "`"),
Aliases: []string{"ls"},
Args: cobra.NoArgs,

View file

@ -447,7 +447,7 @@ func preloadWorkflowNames(client *api.Client, repo ghrepo.Interface, runs []Run)
// Look up workflow by ID because it may have been deleted
workflow, err := workflowShared.GetWorkflow(client, repo, run.WorkflowID)
// If the error is an httpError and it is a 404, this is likely a
// organization-level "required workflow" ruleset. The user does not
// organization or enterprise ruleset workflow. The user does not
// have permissions to view the details of the workflow, so we cannot
// look it up directly without receiving a 404, but it is nonetheless
// in the workflow run list. To handle this, we set the workflow name