Skip to content

[P2] Duplicate Code Detector failing: safe_outputs cannot assign Copilot (target repository not writable) #16778

@github-actions

Description

@github-actions

The Duplicate Code Detector workflow is failing in the safe_outputs job with a permission error when attempting to assign Copilot to an issue.

Error

"type": "FORBIDDEN",
"path": ["replaceActorsForAssignable"],
"message": "Could not assign agent: target repository is not writable."

##[error]Failed to assign copilot to issue #16739 in github/gh-aw: Failed to assign copilot via GraphQL
##[error]Failed to assign copilot to 1 issue(s)

Affected Workflow

Root Cause

The safe_outputs job is trying to assign a Copilot agent to issue #16739, but the GraphQL replaceActorsForAssignable mutation is returning FORBIDDEN. This could be due to:

  1. The target issue being in a restricted state or locked
  2. Insufficient permissions for the GitHub Actions token to assign agents
  3. A temporary GitHub API restriction on agent assignments

Impact

  • Duplicate code analysis results are not being published
  • The workflow fails after the agent job completes (agent itself ran successfully)

Fix Options

  1. Check if issue Duplicate Code: Update Handler Pattern Across update_issue/update_pull_request/update_discussion #16739 is locked or has restricted assignments
  2. Verify that the issues: write permission is properly configured for the workflow
  3. Check if agent assignment via GraphQL requires additional token scopes

References

  • §22167968348 — Failure run (Feb 19)
  • Job: safe_outputs (job ID: 64099636065)

Generated by Workflow Health Manager - Meta-Orchestrator

  • expires on Feb 20, 2026, 7:38 AM UTC

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcookieIssue Monster Loves Cookies!

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions