docs(comments): rewrite comments across all crates to the guidelines
Sweep every first-party crate source (1956 .rs files) to the project comment guidelines: delete redundant restatements, decorative banners, change narration, and end-of-line comments; keep and tighten the crucial ones (invariants, bug rationale, SAFETY blocks, ported-source attribution). No functional code changed. Every edit is proven comment-only against the prior tree by a comment-stripping lexer (string/char/raw-string aware) plus a separate doctest-fence check. Where removing a comment made rustfmt or clippy want to re-lay-out adjacent code, the minimal triggering comment is restored so code tokens stay byte-identical. Gates green: cargo fmt --all --check (0 diffs), cargo check and cargo clippy --workspace --all-targets (0 warnings). Adds scripts/check_codegen_comment_guidelines.py — the enforcement gate for these guidelines (flags banners, end-of-line comments, change narration, and commented-out code).
This commit is contained in:
@@ -33,9 +33,7 @@ use common::{
|
||||
};
|
||||
use kigi_update::auto_update::install_internal_from_base;
|
||||
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
// Artifacts + fixtures
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
/// A real executable whose ARCHIVE clears the 16 MiB parallel threshold (at
|
||||
/// least 2 chunks), so the parallel byte-range path is exercised. The shell
|
||||
@@ -174,9 +172,7 @@ async fn run_one(
|
||||
assert_invariant(home, &prev_good, &new_binary, expect);
|
||||
}
|
||||
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
// Deterministic matrix — single-connection path (small archive)
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
#[tokio::test(flavor = "multi_thread")]
|
||||
#[serial]
|
||||
@@ -224,9 +220,7 @@ async fn blitz_single_connection_matrix() {
|
||||
run_one(&server, Mode::Full, "0.1.182", None).await;
|
||||
}
|
||||
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
// Deterministic matrix — parallel byte-range path (>= 16 MiB archive)
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
#[tokio::test(flavor = "multi_thread")]
|
||||
#[serial]
|
||||
@@ -269,10 +263,8 @@ async fn blitz_parallel_path_matrix() {
|
||||
run_one(&server, Mode::Full, "0.1.182", None).await;
|
||||
}
|
||||
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
// Checksum + smoke-test rejections keep previous-good, then recover WITHOUT
|
||||
// a reset in between.
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
#[tokio::test(flavor = "multi_thread")]
|
||||
#[serial]
|
||||
@@ -312,9 +304,7 @@ async fn smoke_and_checksum_failures_keep_previous_good_then_recover() {
|
||||
assert_invariant(home, &prev_good, &new_binary, Expect::NewBinary);
|
||||
}
|
||||
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
// Bounded randomized fuzz (CI) + ignored stress (1e5+ iterations).
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
/// Cheap deterministic PRNG so the fuzz needs no extra dependency.
|
||||
struct Rng(u64);
|
||||
|
||||
Reference in New Issue
Block a user