fix: stop claiming CODEOWNERS is inheritable org-wide - #3
Merged
Conversation
The previous PR shipped `.github/CODEOWNERS` described as the org-wide
default for every repo without its own. That is wrong, and it was wrong
in the brief this work was written against, so it went in unchallenged.
GitHub's list of community health files an organisation's `.github` repo
can supply as defaults is CODE_OF_CONDUCT.md, CONTRIBUTING.md, discussion
category forms, FUNDING.yml, issue and PR templates, SECURITY.md and
SUPPORT.md. CODEOWNERS is absent from it, and the CODEOWNERS docs read
the file from `.github/`, the root, or `docs/` "of the repository". The
community profile API agrees: mzizi-console resolves its PR template to
mzizi-dev/.github and reports codeowners as null.
So the file shipped last PR governs one repo — this one — and the claim
that it gave the org review routing was exactly the kind of aspiration
described as running that ORG_STANDARDS.md says it does not contain.
What changes:
- `.github/CODEOWNERS` says plainly that it covers this repo only, and
its rules are narrowed to paths that exist here. It no longer lists
/compiler/ and /wrangler.jsonc, which are in other repos and were
never going to match anything from here.
- `CODEOWNERS.example` at the root is the thing to copy per repo,
following the pattern already set by dependabot.example.yml — the
other file with no org-wide fallback.
- ORG_STANDARDS.md moves CODEOWNERS out of the inherited list and into
a new gap 14: no repo in the org has working review routing, and this
repo cannot fix that centrally. Eight small PRs can.
Also fixes the gap ordering, which read 11, 13, 12 after the SHA-pinning
entry was inserted at the wrong anchor.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The comment explaining why Dependabot needs a per-repo file drew the contrast against "CODEOWNERS, issue templates and SECURITY.md" — which asserts the very thing the rest of this PR corrects. Caught by grepping every inheritance claim in the repo rather than only the ones in Markdown. It now names both exceptions, since they are the same instruction: copy the example file into each repo. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Found the hard way: this PR's original title was "fix: CODEOWNERS is not inheritable, so stop claiming it is", and the title lint rejected it. The rule is right and the title was wrong, but the failure reads as a style nit when it is really "your subject happens to start with a filename that is spelled in capitals". That will happen to anyone writing about CODEOWNERS, SECURITY.md, an API or a CI job, which in an org-standards repo is often. Documenting the reword is cheaper than answering it repeatedly, and much cheaper than the alternative someone will eventually propose: relaxing the pattern to allow leading capitals, which would stop it catching the actual mistake it exists for. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
PR #1 shipped
.github/CODEOWNERSand described it as the org-wide default for every repo lacking its own. That is false. This corrects it.Why
CODEOWNERS is not one of the files an org's
.githubrepo can supply as a default. GitHub's inheritable list is CODE_OF_CONDUCT.md, CONTRIBUTING.md, discussion category forms, FUNDING.yml, issue and PR templates, SECURITY.md, SUPPORT.md — CODEOWNERS is absent, and the CODEOWNERS docs read the file from.github/, the root, ordocs/of the repository.The API confirms it.
repos/mzizi-dev/mzizi-console/community/profileresolvespull_request_templatetomzizi-dev/.github— the fallback demonstrably works for templates — and reportscodeowners: null.The premise came from the brief this work was written against and went in unchallenged. It is precisely the kind of aspiration-stated-as-fact that
ORG_STANDARDS.mdclaims not to contain, so it is worth correcting rather than leaving.Changes
.github/CODEOWNERSnow states its scope plainly and is narrowed to paths that exist here. It previously listed/compiler/,/primitives/,/wrangler.jsoncand/.gitleaks.toml— all in other repos, none of which could ever match from this file.CODEOWNERS.example(new, at the root) is the per-repo template, following the pattern already set bydependabot.example.yml— the other thing with no org-wide fallback.ORG_STANDARDS.mdmoves CODEOWNERS out of the inherited list, cites the docs, and adds gap 14: no repo in the org has working review routing, and this repo cannot fix that centrally.mzizi-registryhas the only other CODEOWNERS and it assigns nobody (gap 1); the other seven have none.The practical consequence
Worth knowing before anyone turns on
require_code_owner_reviewin a ruleset: against a repo with no CODEOWNERS it does nothing, and against one with a broken CODEOWNERS it blocks every PR. Both states exist in this org right now.Checks
actionlintclean..github/CODEOWNERSexists in this repo.🤖 Generated with Claude Code