gh-112192: Increase the trace module coverage precision to one decimal#126972
Merged
erlend-aasland merged 8 commits intopython:mainfrom Dec 3, 2024
Merged
gh-112192: Increase the trace module coverage precision to one decimal#126972erlend-aasland merged 8 commits intopython:mainfrom
erlend-aasland merged 8 commits intopython:mainfrom
Conversation
skirpichev
reviewed
Nov 20, 2024
Member
skirpichev
left a comment
There was a problem hiding this comment.
Mostly LGTM, with one comment.
Also, you could change pr description to be more suitable as commit message. Just mention what you do and why it's useful.
skirpichev
approved these changes
Nov 20, 2024
Contributor
Author
|
cc @erlend-aasland |
skirpichev
reviewed
Nov 26, 2024
skirpichev
approved these changes
Nov 26, 2024
Misc/NEWS.d/next/Library/2024-11-18-23-18-27.gh-issue-112192.DRdRgP.rst
Outdated
Show resolved
Hide resolved
erlend-aasland
approved these changes
Dec 3, 2024
Contributor
|
Thanks for the PR, RUANG; thanks for the review Sergey. |
srinivasreddy
pushed a commit
to srinivasreddy/cpython
that referenced
this pull request
Jan 8, 2025
ebonnal
pushed a commit
to ebonnal/cpython
that referenced
this pull request
Jan 12, 2025
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.
Before with the current trace module, you'll have a summary output like this:
This patch increase the precision of cov% to one decimal place so you'll have something like:
So, it makes the impact of small changes visible ;)
This may seem a bit non-sense at the first glance, but it's related to a very practical question - how do we know our coverage improved after some new test cases? With integer percentage, we have a 1% resolution, which means we can't tell if there's a one line improvement if the file is larger than 100 lines. For a file that has 1000 lines, the resolution is 10 lines! It's not trivial!
tracemodule #112192