Guidance on breaking changes #912
All Vouch review confidence checks passed
Residual risk 0.28 = Change Risk (0.50) × (1 − Review Confidence (0.45)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.50 · 394 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.358
Shallow Review Depth
shallow_review_depth
0.344
Real PR Conversation Timeline
1 comments
"Review active on #912"
general
weight: 0.35
b-mehta
The motivation here is that:
1. Users bumping their mathlib versions by a small amount (eg less than one month) should not have to deal with errors in their code
2. But if this is necessary, then mathlib should endeavour to make them as easy to fix as possible
3. We already follow these principles with the deprecation policy and deprecation of modules policy
4. Ecosystems of programming languages are often very strict with breaking changes, and the guidance I add here is relatively very mild to the contributor and harsh on the downstream user. I don't like that it's this way round, but hopefully the change here is a step in the right direction and uncontroversially so. (see eg Rust's policy on breaking changes https://rustc-dev-guide.rust-lang.org/bug-fix-procedure.html, or SemVer's rule on backwards-incompatible changes https://semver.org/#spec-item-8)
5. Lean core sets an expectation that breaking changes will be discussed in the release notes: https://github.com/leanprover/lean4/blob/master/RELEASES.md
6. A number of PRs already discuss breaking changes in their description
7. Hopscotch and its existing CI workflows create issues/PRs giving the mathlib commit and PR description which breaks project code, so requiring it to be mentioned in the description is especially useful for users of hopscotch.
The spirit of this policy already exists in mathlib writings in various guises:
simps because they make it more likely that a new[simp]can produce a breaking change (and more generally the flexible linter)up with the latest Mathlib changes is too onerous, contributing results back to Mathlib may become impossible.
Previous discussion on related points: