Skip to content

Cannot create PR modifying .github/workflows/* due to disallowed workflows:write permission #16163

@elika56

Description

@elika56

Problem

When using gh-aw with strict mode and safe_outputs.create-pull-request,
it is not possible to create a PR that modifies files under:

.github/workflows/

This is because:

  • workflows: write is disallowed in frontmatter
  • contents: write is also rejected in strict mode
  • modifying workflow files requires elevated permissions

Use Case

I am building a CI optimization agent that:

  • analyzes workflow performance
  • proposes improvements
  • creates PRs updating ci.yml

Currently this is blocked by permission constraints.

Question

What is the intended pattern for:

  • agents that need to propose workflow changes?
  • or safe PR creation for workflow file modifications?

Should this:

  1. Be done via external GitHub App with workflow scope?
  2. Be disallowed intentionally?
  3. Be supported in a future version?

Would appreciate clarification or recommended architecture.
``

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions