-
Notifications
You must be signed in to change notification settings - Fork 3
Remove is_disjoint=True
optimization from merge code
#242
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Sentry detected 1 potential issue in your recent changesSuspicion: Removing `finish_merge()` might leave `ReportLine` objects with `coverage=None` from the `is_disjoint=True` optimization, potentially causing `TypeError` when accessed in report processing code like `get_line_totals`.
Did you find this useful? React with a 👍 or 👎 |
Codecov ReportAll modified and coverable lines are covered by tests ✅ ✅ All tests successful. No failed tests found. 📢 Thoughts on this report? Let us know! |
Codecov ReportAll modified and coverable lines are covered by tests ✅
✅ All tests successful. No failed tests found. Additional details and impacted files@@ Coverage Diff @@
## main #242 +/- ##
==========================================
- Coverage 94.21% 94.21% -0.01%
==========================================
Files 1214 1214
Lines 45022 45021 -1
Branches 1435 1435
==========================================
- Hits 42418 42417 -1
Misses 2303 2303
Partials 301 301
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
bbb251c
to
b45b2c9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not opposed to this, but it would be good to understand what exactly is going on?
why exactly is this causing problems? can you create a regression test that reproduces this?
@@ -54,9 +54,7 @@ def merge_reports( | |||
) | |||
|
|||
joined = get_joined_flag(commit_yaml, session.flags or []) | |||
master_report.merge(report, joined, is_disjoint=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it might be a good idea to then revert the whole change, otherwise you will leave this flag and code around unused.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The revert has a bunch of conflicts. To alleviate the customer issues, I would push this out first then clean up the flag in another commit.
This particular optimization is causing some problems with creating a lot of indirect changes. Removing this from the code will fix all these indirect changes caused by incorrect merging. Unfortunately, this change also rolls back the optimization that was introduced.
b45b2c9
to
57df988
Compare
I don't actually know. I spent a day tracing the code and logging stuff, but can't really find anything extremely incorrect about the code. When logging, the intermediate reports are correct, but something about merging with the |
This particular optimization is causing some problems with creating a lot of indirect changes. Removing this from the code will fix all these indirect changes caused by incorrect merging. Unfortunately, this change also rolls back the optimization that was introduced.
@Swatinem this optimization was introduced here, so just checking whether there's any downstream implications of reintroducing the less optimal code. For more information, please take a look at the issue.
Legal Boilerplate
Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. In 2022 this entity acquired Codecov and as result Sentry is going to need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.