Skip to content

feat(repos): the drift Job reads merge settings and bypass actors #6888

Done

Description

@dan-petty

Problem

The nightly drift Job (CronJob repos-drift, #6783) mints an App token with read permissions only (CONST_GITHUB_APP_READ_TOKEN_PERMISSIONS, setting service.github_app.read_only). GitHub returns the merge settings of a repository only to a token with Contents write ("Get a repository"), and the bypass actors of a ruleset only with Administration write ("Get a repository ruleset"). Since #6875 (PR #6878) the Job reports rows 2 and 10 as not readable in each repository each night, so RepositorySettingsUnreadable fires nightly and the merge settings are not checked.

Proposed remedy

Owner decision of 2026-11-23 (#6875, comment 7104241763): the token of the drift Job also asks for Contents write and Administration write.

  • Rename the permission set, the setting and its variable to what they are now (a drift permission set), and fix each doc, spec, manifest, rule text and ADR 0015 Status History line that says read-only.
  • Plan mode still sends GET requests only; a test proves that the drift run with a write-capable token sends no write.

Acceptance criteria

  • A test: the token request of the drift run holds contents: write and administration: write, and every other request of the run is a GET.
  • No doc, spec or manifest calls the drift identity read-only.

Dependencies

None. Related: #6783, #6875.

Activity

  1. added
    type/feature
    source/agent
    status/new
    on Nov 23, 2026
  2. dan-petty commented on Nov 23, 2026

    @dan-petty
    OwnerAuthor
    • Related: fix(repos): a missing merge setting is not drift #6875, which asks for a different change. Both address the drift Job reading merge settings; #6875 identified the false-positive and the owner decision, the candidate implements the token permission change and rename.
  3. added
    value/medium
    effort/medium
    scope/repos
    priority/p2-medium
    owner/agent
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 23, 2026
  4. removed
    status/in-review
    owner/agent
    on Nov 25, 2026
  5. devops-cli-service commented on Nov 25, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-25 17:40 UTC

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/mediumpriority/p2-mediumscope/repossource/agenttype/featurevalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions