From 533835c6b49111d5520ccd7a7bdd008a428b560f Mon Sep 17 00:00:00 2001 From: dev Date: Sat, 21 Nov 2026 19:25:47 +0000 Subject: config,db,fetch,ops: eleven pub(crate) items nothing outside their own file reaches Every one of these was found by taking the marker off and asking the compiler, under both profiles, not by reading a grep. `cargo check --all-targets` builds with `test-support` on, so it never compiles the `cfg(not(test-support))` half of a feature-conditional declaration; the release check is the one that says whether that half can go private, and it refused several of them that the dev check appeared to accept. Narrowed to private: config `shared_workspace` and `store_dir` (both are the `cfg(not(test-support))` twin of a `pub` that only tests reach), db `state_col`, `start`, `call`, `send`, fetch `Body` and `open`, ops `build_success_rate`, `STAGING_GRACE_SECS` and `sweep_staging`. Refused, and now argued in the budget file rather than left unexplained: `EvictPlan`, because `plan_retention` is `pub(crate)` and returns `Vec`, so a private row type is `error: type EvictPlan is private` at `usecase/maintenance.rs:23` where the Vec is bound. `Readers`, `OpenReview` and `ReviewSubject` are the same story in `db`. priv 170 -> 159, overwide 27 -> 22. `cargo check` clean under both profiles with no new warnings, including no new dead_code; `cargo test --test architecture` 16 passed. --- src/ops.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/ops.rs') diff --git a/src/ops.rs b/src/ops.rs index d43c528..0afda76 100644 --- a/src/ops.rs +++ b/src/ops.rs @@ -53,7 +53,7 @@ impl Metrics { } #[cfg(not(feature = "test-support"))] - pub(crate) fn build_success_rate(&self) -> f64 { + fn build_success_rate(&self) -> f64 { Self::build_success_rate_impl(self) } @@ -333,7 +333,7 @@ const STAGING_GRACE_SECS_VALUE: i64 = 3600; pub const STAGING_GRACE_SECS: i64 = STAGING_GRACE_SECS_VALUE; #[cfg(not(feature = "test-support"))] -pub(crate) const STAGING_GRACE_SECS: i64 = STAGING_GRACE_SECS_VALUE; +const STAGING_GRACE_SECS: i64 = STAGING_GRACE_SECS_VALUE; pub fn release_files(cfg: &Config, db: &Db, release_id: i64) -> Result> { let mut out = Vec::new(); @@ -365,7 +365,7 @@ pub fn sweep_staging(cfg: &Config, db: &Db, grace_secs: i64) -> Result<(usize, u } #[cfg(not(feature = "test-support"))] -pub(crate) fn sweep_staging(cfg: &Config, db: &Db, grace_secs: i64) -> Result<(usize, u64)> { +fn sweep_staging(cfg: &Config, db: &Db, grace_secs: i64) -> Result<(usize, u64)> { sweep_staging_impl(cfg, db, grace_secs) } -- cgit v1.2.3