docs(contributing): split conventions.rst into one file per anchor (#918) - #945
Conversation
|
Verified at Content preservation, measured rather than inspected. Reconstructing the original by concatenating So no prose was altered. One Reference integrity, from my own nitpicky build (
The residual 1289 are the pre-existing noise floor, all in unrelated categories (1202 It caught the functional break I had flagged as the real risk. Two small discrepancies with the author's report, neither material, both stated rather than smoothed over. It reported the baseline failure count as 21+3 for one suite and 4 for the other (25 failures, 3 errors); running them together I measured 24 failures, 3 errors. And it reported 1287 warnings where my count is 1289 — different counting expressions, not a different build. I did not run the baseline build, so I cannot confirm its "zero-line warning-set diff" literally; what I have instead is targeted and stronger for the question that matters, namely that every split-specific warning category is empty. |
|
NEEDS CHANGES at The
Round 2 rewrites that paragraph to be true of an index while keeping the same voice, both owner quotes, and the Everything else verified, independently of the author's report. Reconstruction: 966 lines, md5 The review also mutation-tested all five new One prediction of mine it disproved: I had briefed it that cross-file prose breakage was the most likely defect. It found the split boundaries coincide almost exactly with the prose's own referential boundaries — every directional phrase in the four child pages points within its own file. The index preamble is the sole residue. |
6ed02cd to
7193629
Compare
) Part 2 of #918. The 966-line docs/source/contributing/conventions.rst carried four unrelated rulings on one page; split into docs/source/contributing/conventions/, one file per `.. _label:` anchor, plus index.rst carrying the toctree and the `.. important::` preamble. Pure move -- every split file is byte-identical to its slice of the original. - Anchors are global in Sphinx, so no `:ref:` needed touching; only the one `:doc:` path -- docs/source/index.rst's toctree entry -- named the retired bare document and now points at conventions/index. - test_sentinel_exports_unit.py's `_sentinel_section` used to slice between `.. _sentinel-convention:` and `.. _registry-protocol:` in one shared file, exactly what #930 flagged as the split's blocker. Now reads sentinel-convention.rst whole. - test_conventions_doc_claims.py rewritten for the split: reads each anchor's own file, and gains tests pinning the split's own shape (every anchor lives in exactly one file, the index's toctree lists all four, the top-level index points at the new page). - Corrected ten prose citations of the old single-file path, across pcapkit/corekit/sentinels.py and eight test files, to name the file each now actually lives in. - Cross-review round: the index's `.. important::` preamble carried over unedited, so it still spoke as a single page -- "this page records" every ruling, and told a future contributor to write a new one "onto this page". Both went false once the index stopped holding any ruling of its own. Reworded to speak as a hub (the standing #918 instruction now points at "the page that covers it"), same voice and both owner quotes kept, and pinned with a test that bans the self-referential "this page" from the index and checks the corrected phrase landed. Build: nitpicky sphinx-build warning set unchanged (1287, byte- identical to 9ea0d6a once build-order nondeterminism in ambiguous xref candidate lists is normalised); isort clean; pylint 10.00/10 on sentinels.py (unchanged). The four split pages remain byte-identical to their slices of 9ea0d6a's original conventions.rst.
7193629 to
9f86eba
Compare
|
GOOD TO GO at The four child pages are still byte-identical to their exact slices of The three corrections:
The author chose to pin this with a test, and rejected the broader version I floated, correctly. My suggestion was to assert that no page says "this page" about a sibling's content; it pointed out the four child pages legitimately say "this page" about their own, so that check needs semantic judgement about where a ruling ought to live — the very thing a human reviewer just did — and would be false-positive-prone. It scoped the ban to It also flagged something against its own interest, which is worth recording: I asked for the paragraph to get no longer, and it came out five words longer (175 vs 170). It said so plainly rather than claiming compliance, having traded economy against unavoidable new content. Accepted. I rebased both this and #943 onto One note on my own process: the first Unpublished and yours to merge, once CI reports on the rebased head. |
make pylint,make mypy,make isort)make testpasses, and a test case covers the changeWhat is the purpose of your pull request?
docs— documentation onlyDescription
Part 2 of #918 (three parts total; part 1 is the harvest sweep, part 3 is a
standing obligation). Splits the 966-line
docs/source/contributing/conventions.rst-- four unrelated design rulings onone page -- into
docs/source/contributing/conventions/, one file per.. _label:anchor (mint-criterion,sentinel-convention,registry-protocol,extension-header-subclassing), plusindex.rstcarrying the toctree and the
.. important::preamble. Every split file isbyte-identical to its slice of the original.
Fixes the one
:doc:reference that breaks on a move (docs/source/index.rst'stoctree entry) and the file-path assumptions in
tests/corekit/test_sentinel_exports_unit.pyandtests/project/test_conventions_doc_claims.py, which previously sliced thesingle page between two anchors -- exactly what #930 flagged as this split's
blocker.
:ref:targets needed no changes; Sphinx anchors are global.Verified with a nitpicky
sphinx-build: warning set is unchanged (1287,byte-identical to
9ea0d6a5aonce ambiguous-xref candidate ordering isnormalised) -- no new
undefined labelorunknown documentwarnings.