Code change report fails on feature branches by hardcoding develop

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • WT12.0.0, 9.1.0-rc0
    • Affects Version/s: None
    • Component/s: Evergreen
    • None
    • Storage Engines
    • 243.68
    • None
    • None

      Problem

      The code-change-report Evergreen task fails on feature-branch projects (for example tiered-depr). Patch diffs are computed with git merge-base develop HEAD in test/evergreen/code_change_report/git_diff_tool.py. After git.get_project on a non-develop branch there is no local develop ref, so the command fails.

      test/evergreen/coverage-report.sh then checks out previous-complexity code via last_commit_from_dev (git merge-base origin/develop HEAD), which would also fail or compare against the wrong branch.

      Seen on https://spruce.corp.mongodb.com/task/tiered_depr_code_statistics_code_change_report_patch_a1133a750630aba8bfebde2fdda7a473fb17c7c1_6a88652f819e1000079d0914_26_08_21_14_48_19/logs?execution=0 (GitHub PR 14521, base tiered-depr).

      Change

      Pass Evergreen branch_name into the coverage/report scripts. Resolve origin/ then }} and use that as the merge-base for both the patch diff and the previous-complexity checkout. Leave {{dist/common_functions.py last_commit_from_dev unchanged (used by s_fast).

      Test

      Exercise merge-base resolution against a non-develop ref. The Evergreen code-change-report task on a feature-branch patch is the real coverage.

            Assignee:
            Luke Pearson
            Reporter:
            Luke Pearson
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: