[BUG]: ComputeChangedFiles and ComputeAffectedTests reflect non-PR changes from merged base branch #5570
Labels
bug
End user-perceivable behaviors which are not desirable.
Impact: Medium
Moderate perceived user impact (non-blocking bugs and general improvements).
Work: High
It's not clear what the solution is.
Describe the bug
In the current workflow, ComputeChangedFiles and ComputeAffectedTests functions may inaccurately include changes from the base branch when a merge is performed before the latest commit. This behavior results in additional files being referenced as "changed," even though they are not directly modified in the current PR.
However, once a subsequent commit is pushed to the PR, this issue typically resolves, and only the actual changes in the PR are reflected.
This issue affects the code coverage report by unnecessarily including non-PR changes in the list of changed files and reporting them in the coverage results after a merge with the base branch. As shown in this coverage report, even files unrelated to the PR (such as a wiki page with no Kotlin file changes) can appear with coverage data simply due to changes from the base branch merge.
Steps To Reproduce
Expected Behavior
The ComputeChangedFiles and ComputeAffectedTests retrievals should list only the files that have been changed or affected by the PR commits and exclude any unrelated changes from the merge with the base branch.
Screenshots/Videos
No response
What device/emulator are you using?
No response
Which Android version is your device/emulator running?
No response
Which version of the Oppia Android app are you using?
No response
Additional Context
No response
The text was updated successfully, but these errors were encountered: