feat(core): validate deferred_apply_threshold < compaction_threshold#1381
Merged
feat(core): validate deferred_apply_threshold < compaction_threshold#1381
Conversation
…1302) Enforce threshold ordering invariant at config load and in --init wizard. Both thresholds must be finite and in (0.0, 1.0) exclusive range. Wizard re-prompts on violation instead of silently accepting. Add config.validate() call in tui_remote after Config::load().
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
deferred_apply_threshold < compaction_thresholdordering invariant inConfig::validate(), covering all startup paths (runner, daemon, ACP, tui_remote)--initwizard re-prompts on ordering violation instead of silently acceptingeprintln!warning inbuild_config()config.validate()call intui_remoteafterConfig::load()Closes #1302
Test plan
cargo +nightly fmt --checkpassescargo clippy --workspace --features full -- -D warningspassescargo nextest run --workspace --features full --lib --binspasses (4776 tests, 0 failures)--initwizard, enter deferred threshold >= 0.80, verify re-promptdeferred_apply_threshold = 0.85in config.toml, verify startup error