Skip to content

Update approve-workflow-run safe output description - #53115

Merged
pelikhan merged 1 commit into
mainfrom
copilot/update-approve-workflow-run-description
Aug 16, 2026
Merged

Update approve-workflow-run safe output description#53115
pelikhan merged 1 commit into
mainfrom
copilot/update-approve-workflow-run-description

Conversation

CopilotAI commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

approve-workflow-run was described as fork-PR-specific, but it applies to any pull request workflow run requiring approval, including Copilot-created PRs.

  • Reference docs

    • Reworded the safe output summary and detailed reference to describe "action required" / required-approval workflow runs.
    • Added Copilot-created PRs as an explicit example.
  • Schema and tool metadata

    • Updated JSON schema descriptions and MCP tool descriptions to avoid fork-only language.
  • Config comments and validation text

    • Aligned inline comments and the external-token validation message with the broader approval model.
safe-outputs:
approve-workflow-run:
allowed-workflows: [ci.yml]github-token: ${{ secrets.APPROVE_WORKFLOW_RUN_TOKEN }}

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
CopilotAI requested a review from pelikhanAugust 16, 2026 12:47
@pelikhan
pelikhan marked this pull request as ready for review August 16, 2026 12:51
CopilotAI balanced review requested due to automatic review settings August 16, 2026 12:51
@pelikhan
pelikhan merged commit c4d1d53 into mainAug 16, 2026
@pelikhan
pelikhan deleted the copilot/update-approve-workflow-run-description branch August 16, 2026 12:51

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Broadens approve-workflow-run documentation beyond fork PRs to all eligible PR workflow runs requiring approval, including Copilot-created PRs.

Changes:

  • Updates reference documentation and examples.
  • Aligns schemas, tool metadata, validation text, and configuration comments.
  • Retains existing approval eligibility and security constraints.
Show a summary per file
FileDescription
pkg/workflow/safe_outputs_validation.goBroadens validation error wording.
pkg/workflow/safe_outputs_config_types.goUpdates configuration comment.
pkg/workflow/js/safe_outputs_tools.jsonUpdates MCP tool description.
pkg/workflow/approve_workflow_run.goUpdates configuration type documentation.
pkg/parser/schemas/main_workflow_schema.jsonBroadens schema descriptions.
docs/src/content/docs/specs/safe-outputs-specification.mdUpdates specification terminology.
docs/src/content/docs/reference/safe-outputs.mdUpdates summary table wording.
docs/src/content/docs/reference/safe-outputs-pull-requests.mdDocuments broader approval scenarios.
actions/setup/js/types/safe-outputs-config.d.tsUpdates TypeScript configuration documentation.
actions/setup/js/safe_outputs_tools.jsonUpdates setup-action tool metadata.
.github/aw/safe-outputs-automation.mdAligns automation reference and token comments.

Review details

  • Files reviewed: 10/11 changed files
  • Comments generated: 2
  • Review effort level: Balanced

{
"type": "object",
"description": "Configuration for approving workflow runs that are awaiting approval for a fork pull request.",
"description": "Configuration for approving workflow runs that are awaiting required approval.",

return errors.New(
"safe-outputs.approve-workflow-run: requires an external github-token or github-app because github.token cannot approve workflow runs for fork pull requests.\n\n" +
"safe-outputs.approve-workflow-run: requires an external github-token or github-app because github.token cannot approve workflow runs requiring approval.\n\n" +
github-actionsBot added a commit that referenced this pull request Aug 17, 2026
Weekly Safe Outputs specification review found that the
approve_workflow_run safe output type (added in v1.28.4, PR #52541,
refined in #53115) had no corresponding conformance checks in
scripts/check-safe-outputs-conformance.sh.
Adds TYPE-013 validating: run_id positive-integer validation, staged
preview support, pull_request/waiting eligibility checks, allowed-
workflows matching with yml/yaml normalization, triggering/allowed
pull request authorization, pull_request_target and fork rejection,
protected-file checks, explicit external credential requirement, and
Abort classification for warn-mode threat detection (spec Section 7.3).
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This pull request is included in a new release.

Release: v0.87.1

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@pelikhan