Skip to content

Reword comments and docs in plain language - #12

Merged
djgormley merged 1 commit into
mainfrom
style/voice-review
Oct 27, 2026
Merged

djgormley merged 1 commit into
mainfrom
style/voice-review

Conversation

@djgormley

Copy link
Copy Markdown
Contributor

Rewrites the comments, docstrings, docs, READMEs and CHANGELOG wording so they read plainly and in one voice. I went through all 584 code and doc files in the repo and changed 413 of them. The step-by-step explanations added in #11 for the detector and archive code keep their detail, but the semicolon chains, "not X" framing, dash asides, banners, arrows and history notes ("now", "previously", "kernel core 2.2.0 adds") are gone, and the mechanism sentences are in the passive. Line comments are short lowercase fragments, docstrings open with a purpose line, and British spellings are now American. No code changed. This branch sits on top of #11, so it should go in after that one.

A number of comments didn't match the code, so I fixed them while I was there. The fine_reduction docstring pointed at a GPU test file that doesn't exist, and now names test_cupy_fine_reduction_matches_float64_prototype_within_ulp_gate. The DS001 data sheet said per-pilot products store CFAR columns and an any-bin detection list, but only fine_power_u64 and the contract scalars are stored, as PRODUCT_SCHEMA.md says. USAGE.md called the guard and reference offsets fine bins (they're detector bins) and said both shipped profiles use 16384-sample frames, which is only true of the reference and CHIME profiles. _run_json said it never raises, but it raises SystemExit when the CLI doesn't accept --json. test_c_header.c still said core 3.0.0 ABI while config.h is at 4.0.0, and the fxfft256_ref.c self-check exits with status 2 where the comment said it aborts. The line-number citations in the archive tests had all drifted, so they name the function now.

Checked on Python 3.12 (archive-local venv), running the make release-check steps one by one. ruff check ., generate_doc_specs.py --check, check_no_legacy_guard_terms.sh, the six check_current_* scripts, emit_fxfft_tables.py --check and compileall all pass. pytest tests -q -p no:cacheprovider --ignore=tests/kernel --deselect tests/core/test_reference_pfb_gpu.py gives 3673 passed, 71 skipped and 2 deselected. make -C cuda test_c_header test_ref builds and runs, and the check-profile, check-layout, bundle export and validate, and list-channels commands from release-check all exit 0. The GPU tests were run during the edit on the RTX 5000 Ada (pytest tests/kernel gave 109 passed, and make -C cuda test at K=128 passed). Every changed Python, C, CUDA, shell, YAML and TOML file has the same code as the base once comments and docstrings are stripped. The other 49 files are Markdown, TeX, TikZ and text, and their code blocks are unchanged except for comment lines. DS001 and UG001 build with latexmk, and the three standalone figures build with pdflatex.

Comment edits change file hashes, and a few tools check their own. operating_policy.py rejects a policy compiled from the old bytes, current_geometry_sensitivity.py won't reuse a study directory from the old driver, the SDR runners and run_fine_validation_campaign.py refuse plans prepared before the edit, and a per-pilot checkpoint won't resume because package_source_sha256 changes. So any of those that are in flight should finish before this merges. The dtv-rs model_band records pin the hash of tools/validate_proxy_confidence_band.py at commit 0ef044e, so they have to be reproduced from that commit. A rebuilt libpilotproxy.so won't be byte-identical to the kernel builds of record, because __LINE__ shows up in the error messages, but the arithmetic is the same. The kotekan copy of fxfft256_ref.c now differs from this one in comments only.

I didn't touch anything under docs/evidence, docs/runtime_freezes or the dated data/provenance directories, since those are frozen records. Both evidence verify.py scripts and the three SHA256SUMS still pass. The same goes for the generated files (fxfft_master_twiddle.h, wvu_palette.py, wvu_palette.tex), the LimeSuite headers, CITATION.cff, freeze_estimator_transfer.py (its blob is checked against the publication tag), and the two worker .cpp files whose hashes are pinned in the evidence. Printed, asserted and hashed strings weren't touched either, so some help text and output strings still have dropped spaces ("approximately310kHz", "must be1", "All0.001 rows") from 1.0.0. Those need a code change. A few doc disagreements also need a decision before I touch them. The datapath figure labels the fine decision "(deployed)" while DS001 calls it an inactive candidate. METHOD_SPEC and DESIGN_DECISIONS describe channel 14's lower reference differently. And docs/ADDING_A_READER.md and docs/archive-results-design.md are cited but missing, so either the docs get written or the references change.

@djgormley
djgormley merged commit bcb788a into main Oct 27, 2026
8 checks passed
@djgormley
djgormley deleted the style/voice-review branch November 2, 2026 01:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant