diff --git a/QUICKSTART.adoc b/QUICKSTART.adoc index e6514ec..78f63ad 100644 --- a/QUICKSTART.adoc +++ b/QUICKSTART.adoc @@ -36,6 +36,22 @@ worse on none), *pareto-regression* (worse on at least one, better on none), description), or *neutral*. Advisory by default; `--check --pr-body pr.txt` fails the run on an undocumented, measured regression or trade-off. +[IMPORTANT] +==== +*`--check` cannot block a merge today, by design.* Only objectives backed by +`Measured` or `Calibrated` inputs may fail a run, and every resource figure +OikosBot currently produces is a heuristic `Estimated` value — the calibration +framework at `crates/oikosbot-analysis/src/calibration.rs` exists but is not +yet wired into the analyzer, which still uses a naive complexity-derived +estimate. + +So `--check` reports and warns, but always exits 0. It says so *loudly* — a +`::warning::` annotation naming the confidence level — rather than passing +silently. A gate that quietly does nothing is indistinguishable from one that +passed, which is precisely the failure mode OikosBot exists to find. +Enforcement becomes real when calibration is wired in. +==== + === Per-repo configuration `check`, `report`, and `compare` honor an `.oikos.yml` in the analyzed diff --git a/action.yml b/action.yml index e31fa3e..529349a 100644 --- a/action.yml +++ b/action.yml @@ -49,7 +49,12 @@ inputs: required: false default: '' check: - description: 'compare mode: fail on an undocumented, measured Pareto regression/trade-off (true/false)' + description: >- + compare mode: fail on an undocumented, measured Pareto + regression/trade-off. NOTE: cannot block today — every resource figure is + a heuristic Estimated value and only Measured/Calibrated inputs may + fail a run, so this warns loudly and exits 0 until calibration is wired + in (see QUICKSTART). required: false default: 'false' image: diff --git a/crates/oikosbot-cli/src/main.rs b/crates/oikosbot-cli/src/main.rs index f9d6a73..0b26b5b 100644 --- a/crates/oikosbot-cli/src/main.rs +++ b/crates/oikosbot-cli/src/main.rs @@ -364,8 +364,27 @@ fn main() -> Result<()> { oikosbot_pareto::ParetoVerdict::Regression | oikosbot_pareto::ParetoVerdict::TradeOff ); - if check && needs_documentation && assessment.actionable && documented != Some(true) { - std::process::exit(1); + if check && needs_documentation && documented != Some(true) { + if assessment.actionable { + std::process::exit(1); + } + // Enforcement was asked for and cannot be delivered: the + // driving objectives rest on heuristic estimates, which by + // design may not block a merge. Say so unmissably. A gate + // that silently no-ops is indistinguishable from one that + // passed, which is the failure mode this tool exists to + // find — so it must never be silent about its own limits. + eprintln!( + "::warning::--check requested but NOT enforced: the objectives driving \ + this {} verdict are {:?}, and only Measured or Calibrated inputs may \ + block. Reported as advisory. See docs: enforcement is inert while \ + resource figures remain heuristic estimates.", + match assessment.verdict { + oikosbot_pareto::ParetoVerdict::Regression => "pareto-regression", + _ => "trade-off", + }, + confidence, + ); } }