feedback icon indicating copy to clipboard operation
feedback copied to clipboard

Align "Files Changed" Tab in Codecov UI with Git Diff

Open vlad-ko opened this issue 1 year ago • 3 comments

Context and Problem Statement

In the Codecov PR view page, the "Files Changed" tab often shows discrepancies compared to what the user expects based on the Git diff. Customers frequently face confusion because:

  1. Files not part of the git diff sometimes appear in the "Files Changed" tab.
  2. Files that are part of the diff can mistakenly show up under "Indirect Changes" or fail to appear entirely in the "Files Changed" tab.

This inconsistency leads to frustration and misunderstanding about which files are acknowledged, ignored, or missing reports.

Proposed Solution To eliminate confusion, Codecov should adopt the following rule: The "Files Changed" tab should always and only display files contained in the Git diff for the PR.

Once we establish that the "Files Changed" tab matches the Git diff, files can then be categorized as follows:

  • Files Ignored
    • Non-testable files like txt, css, yaml, html, etc., that Codecov intentionally excludes.
  • Files Missing Reports
    • Testable files for which Codecov did not receive coverage reports.
  • Files with Coverage Impact
    • Files where coverage data was received, and changes impact coverage metrics (as currently shown).

Goal The goal is to provide a clear, predictable, and consistent experience for customers:

  • The "Files Changed" tab reflects only the files in the Git diff.
  • Customers can easily understand why a file appears and in which category it falls.
  • The confusion around why files are appearing or missing is eliminated.

Summary The proposal simplifies the experience by ensuring that the "Files Changed" tab strictly aligns with the Git diff. From there, Codecov can handle categorization and presentation of files, but the starting point will always be a consistent and accurate reflection of the Git diff.

This change addresses one of the most frequent sources of customer confusion and improves transparency in how Codecov processes file changes.

vlad-ko avatar Dec 17 '24 14:12 vlad-ko

This makes a lot of sense to me.

rohan-at-sentry avatar Dec 17 '24 14:12 rohan-at-sentry

The "Files Changed" tab should always and only display files contained in the Git diff for the PR.

this could be just as awkward when we display project coverage for a commit whose project coverage base is not the same as the PR base. not saying nothing should be done, i just think we need to have a big think about streamlining and clarifying our product

matt-codecov avatar Dec 17 '24 22:12 matt-codecov

passing to @codecovdesign as we've done extensive discovery work around this idea in the past, could be useful to revisit and see if we want to take any action on this yet.

eliatcodecov avatar Jan 08 '25 16:01 eliatcodecov