[infra] Add a docs-only review guide - #971
Conversation
Fills the docs-only row of the Change-Type Review Guides table in code_review.md, following the shape of the existing runtime/ and Python-Java bridge guides: a focused checklist, a validation section, and examples drawn from past reviews on merged PRs. Generated-by: Claude Code 2.1.223
|
Thanks for taking this on @weiqingy. The PR itself looks good to me. Regarding our AI-assisted review experiment in #894, however, I found that the detailed PR description added more overhead than it removed for this particular change. Much of the description records the investigation process, such as discarded drafts and how individual repository facts were verified, rather than the final decisions that need human review. The Overall, for a PR of this scope and size, I do not think an additional detailed implementation description is necessary. A brief summary of the purpose, key decisions or limitations, and validation performed would be sufficient. |
|
Thanks for the feedback, it makes sense. Agreed that a detailed description was not worth it for a change this size, and that it should not be restating the document the PR adds. #965 and #981 are still open and both use the same format, so there are two more samples if you want them. Once those have been through review I will put together the guide PR with all of your feedback folded in. |
Linked issue: #894
Purpose of change
Fills the
docs-onlyrow that #911 left asplanned, the third of the four per-change-type guides. #957 filled thePython-Java bridgerow the same way, and #961 is theapi/row.Runtime flow
No executable path changes. The flow this PR completes is the routing one that #911 introduced.
A reviewer opens a documentation PR, reads the Change-Type Review Guides table in
code_review.md, and follows the row matching the change. Before this PR thedocs-onlyrow terminated at the wordplanned, so the reviewer fell back to the general passes, which are written for code. After it, the row resolves toreview-guides/docs-only.md, which narrows the passes to this change type and then hands back to the general ones.Key decisions
The
Validationsection leads with a negative fact rather than a command list, because for this change type that is the useful content. A change underdocs/contentruns the full CI matrix and passes without any job reading a changed line.ci.ymlhas no path filter so every job runs, ruff runs withpython/as its root, and the site build lives indocs.yml, triggered on a schedule and by manual dispatch rather than on pull requests. There is no markdown linter and no link checker in the repo. A guide that listed commands here would be inventing them.No local site-build command is published.
tools/docs.shmutates global git config with a container-only path, fetches a Linux x86-64 Hugo binary, and needs the theme submodule initialized, so it is not something a reviewer can be told to run.The checklist is five bullets rather than the sibling's six. A sixth was drafted, covering pages that document a feature without naming its language scope, and cut when its evidence proved wrong: every section I had flagged does carry a scope hint, in a phrasing variant my original search missed. Nothing was added back to restore the count.
Both example rows cite docs findings raised on merged, genuinely documentation-only PRs, so neither row illustrates its change type with a PR of a different type.
Implementation Description
Behavioral contracts
The guide is prose, so its contracts are the claims it makes about this repository. Each is separately checkable.
docs/content.python/as its root, so it does not reachdocs/.weightorders a page among the pages it sits beside.Failure behavior
There is no runtime failure path. The failure mode is a wrong claim, and nothing in CI would catch one: RAT excludes
docsandreview-guides, no markdown linter exists, and the relative link incode_review.mdis checked by nothing.That makes a false sentence here worse than a false sentence in a comment, because it is guidance a reviewer acts on. One such claim did occur and is worth stating. An earlier draft said no CI job reads anything under
docs/. That is false:SchemaParityTestandtest_specs.pyboth readdocs/yaml-schema.json, so a PR touching only that file is documentation-only by path and is validated byte for byte. Contract 1 is now scoped todocs/content, verified separately, with the only references to that path outside the subtree being Hugo's own settings indocs/config.toml.One consequence I did not try to solve here: a
docs/yaml-schema.jsonPR is docs-only by path, so the table routes it to this guide, which is then the wrong guide for it. That seems better settled once the remaining rows are filled than by carving an exception into this one.Tests
Not applicable in the executable sense, documentation only, no logic.
./tools/check-license.shpasses. No license header is needed:tools/.rat-excludescoversreview-guides/, and.licenserc.yamlignores**/*.md.Each contract above was verified against source rather than written from memory.
docs/contenttools/, and every.java,.py,.shfordocs/contentandcontent.zh. Only hits aredocs/config.toml, consumed bytools/docs.shfromdocs.ymlalonedocs.yml'son:block isscheduleplusworkflow_dispatch, nopull_requesttools/lint.sh, on both its uv and pip pathstools/lint.sh,tools/ut.sh, ruff config, pytest config foraddoptsanddoctest_globweightorderingdocs/README.mdAPI
No. No code or public API change, and no compatibility impact for any caller.
For a reader, one row of the
code_review.mdtable changes fromplannedto a link. The two already-linked rows and the two stillplannedare untouched, and the Focus cell wording is unchanged from #911.Documentation
doc-includedWas this patch authored or co-authored using generative AI tooling?
Generated-by: Claude Code 2.1.223