codeowners-validator icon indicating copy to clipboard operation
codeowners-validator copied to clipboard

0.7.4 Fails with missing `read:org` scope

Open aricallen opened this issue 7 months ago • 1 comments

Description

We updated to 0.7.4 and now see an error: level=fatal msg="while checking if 'owners' checker is satisfied: missing scopes: \"read:org\""

Downgrading back to 0.7.2 fixes the issue.

Expected result

Updating to the latest patch version should work the same without required changes.

Actual result

The check failed.

Steps to reproduce

Upgrade to 0.7.4 without changing anything else.

Troubleshooting

Downgrading to 0.7.2 fixed the issue.

aricallen avatar May 01 '25 16:05 aricallen

Workaround: include the action twice


      - name: GitHub CODEOWNERS Validator
        uses: mszostok/[email protected]
        if: github.event.pull_request.head.repo.full_name == github.repository
        with:
          checks: "files,duppatterns,syntax"
          experimental_checks: "notowned,avoid-shadowing"

      # downgrading to 0.7.2 for owners check to avoid issues with token permissions check,
      # see https://github.com/mszostok/codeowners-validator/issues/224
      - name: GitHub CODEOWNERS Validator
        uses: mszostok/[email protected]
        if: github.event.pull_request.head.repo.full_name == github.repository
        with:
          checks: "owners"
          github_access_token: "${{ secrets.SPECIAL_GITHUB_ACCESS_TOKEN }}"
          owner_checker_owners_must_be_teams: true

ov7a avatar Jul 17 '25 14:07 ov7a