docs: Correct tolerance default attribution - #58
Open
Hayden Anderson (haydena7) wants to merge 1 commit into
Open
docs: Correct tolerance default attribution#58Hayden Anderson (haydena7) wants to merge 1 commit into
Hayden Anderson (haydena7) wants to merge 1 commit into
Conversation
Hayden Anderson (haydena7)
requested review from
EgeKaraismailogluQC,
Marius Merkle (MariusMerkleQC) and
Oliver Borchert (borchero)
as code owners
September 4, 2026 17:09
Copilot started reviewing on behalf of
Hayden Anderson (haydena7)
September 4, 2026 17:09
View session
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The updated paragraph includes a potentially confusing comparison to polars.Expr.is_close defaults even though Diffly calls Expr.is_close with explicit tolerances.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Updates the tolerances documentation to correctly attribute Diffly’s default float tolerances to Polars testing utilities, preventing readers from misinterpreting how strict Diffly’s default comparisons are.
Changes:
- Reworded the “Default behavior” paragraph to attribute
abs_tol=1e-08/rel_tol=1e-05topolars.testing.assert_frame_equal. - Added an explanatory note contrasting these defaults with Python’s
math.isclosedefaults.
File summaries
| File | Description |
|---|---|
| docs/guides/features/tolerances.ipynb | Corrects documentation text about default tolerance provenance. |
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Oliver Borchert (borchero)
approved these changes
Sep 4, 2026
Oliver Borchert (borchero)
left a comment
Member
There was a problem hiding this comment.
Thank you!
Oliver Borchert (borchero)
enabled auto-merge (squash)
September 4, 2026 17:23
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.
Motivation
The tolerances guide states that the default
abs_tol=1e-08/rel_tol=1e-05match Python'smath.isclosedefaults. They don't —math.isclosedefaults torel_tol=1e-09,abs_tol=0.0. The values actually matchpolars.testing.assert_frame_equal.The error points in the risky direction: a reader trusting the guide would believe diffly is stricter (~9 significant figures) than it is (~5).
Changes
docs/guides/features/tolerances.ipynbto attribute the defaults topolars.testing.assert_frame_equal.Markdown cell only; no cells were executed and no outputs changed. The
compare_framesdocstring note that the implementation mirrorsmath.iscloseis left as-is, since that statement is about the formula and is correct.