-
Notifications
You must be signed in to change notification settings - Fork 349
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
fix(builder): strenghten matching dependencies heuristic #5187
Conversation
Part of #5090 - FYI @lburgazzoli |
✔️ Unit test coverage report - coverage increased from 36% to 36.2% (+0.2%) |
@squakez can you add some better release notes ? it is not clear to me what is the motivation of this change and how it differs form the current behavior and what would be the impact. |
Sure. Done. Thanks. |
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.
Good work. Thanks!
It failed when we had odd number of dependencies
08452f6
to
6ca3ba8
Compare
✔️ Unit test coverage report - coverage increased from 36% to 36.2% (+0.2%) |
The
TestRunBuildOrderStrategyMatchingDependencies
uses to be flaky. I've investigated and the root cause seems to be the heuristic we are using to detect matching dependencies. The following piece of codemissing >= len(required)/2
seem to be the problem, in the sense that when the number ofrequired
is odd, then, the code is rounded to a integer value that is not matching the condition. The ideal solution is to add +1 to that division, or removing the equality which would sort the same effect.This PR address the problem. The heuristic used is strengthen against this corner case and validated with a few unit test.
Release Note