Single-source aura-campaign's deflation constants against aura-cli's #199

Closed
opened 2026-07-03 19:49:40 +02:00 by Brummel · 1 comment
Owner

aura-campaign's DEFLATION_N_RESAMPLES/DEFLATION_BLOCK_LEN (crates/aura-campaign/src/lib.rs) duplicate aura-cli's private DEFLATION_N_RESAMPLES/DEFLATION_BLOCK_LEN constants (crates/aura-cli/src/main.rs, select_winner) — a second, unsynced copy of the deflation-bootstrap tuning values, no shared source. Unlike the metric rosters (#190), a drift here is silent: a value edited in one crate and not the other doesn't refuse anything, it just produces a wrong deflation result.

Likely shape: promote one copy to a shared location (aura-analysis or aura-registry, wherever the deflation bootstrap itself lives) and have both aura-cli and aura-campaign import it, rather than each crate carrying its own literal.

  • depends on: nothing
  • context: reviewer finding from cycle 0107 task 5 (aura-campaign preflight); aura-campaign's copy is currently pub but unused until a later task's execute wires deflation through.
`aura-campaign`'s `DEFLATION_N_RESAMPLES`/`DEFLATION_BLOCK_LEN` (crates/aura-campaign/src/lib.rs) duplicate `aura-cli`'s private `DEFLATION_N_RESAMPLES`/`DEFLATION_BLOCK_LEN` constants (crates/aura-cli/src/main.rs, `select_winner`) — a second, unsynced copy of the deflation-bootstrap tuning values, no shared source. Unlike the metric rosters (#190), a drift here is silent: a value edited in one crate and not the other doesn't refuse anything, it just produces a wrong deflation result. Likely shape: promote one copy to a shared location (`aura-analysis` or `aura-registry`, wherever the deflation bootstrap itself lives) and have both `aura-cli` and `aura-campaign` import it, rather than each crate carrying its own literal. - depends on: nothing - context: reviewer finding from cycle 0107 task 5 (`aura-campaign` preflight); `aura-campaign`'s copy is currently `pub` but unused until a later task's `execute` wires deflation through.
Author
Owner

Shared home resolved: aura-registry. The deflation-bootstrap counts are consumed only by optimize_deflated (crates/aura-registry/src/lib.rs), and both duplicate copies (aura-cli, aura-campaign) existed solely to feed its call sites — so the crate that owns the bootstrap is the natural single source, with the other two crates importing it (aura-campaign re-exporting to keep its public path stable). DEFLATION_SEED stays cli-local (no campaign twin, not part of the duplication). Values unchanged (1000 / 5); behaviour-preserving.

Shared home resolved: **aura-registry**. The deflation-bootstrap counts are consumed only by `optimize_deflated` (`crates/aura-registry/src/lib.rs`), and both duplicate copies (aura-cli, aura-campaign) existed solely to feed its call sites — so the crate that owns the bootstrap is the natural single source, with the other two crates importing it (aura-campaign re-exporting to keep its public path stable). `DEFLATION_SEED` stays cli-local (no campaign twin, not part of the duplication). Values unchanged (1000 / 5); behaviour-preserving.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Brummel/Aura#199