Closed Bug 1742652 Opened 2 years ago Closed 2 years ago

Fix drop of code coverage on 25 October 2021

Categories

(Testing :: Code Coverage, defect)

Default
defect

Tracking

(firefox-esr91 unaffected, firefox94 unaffected, firefox95 wontfix, firefox96 fixed)

RESOLVED FIXED
96 Branch
Tracking Status
firefox-esr91 --- unaffected
firefox94 --- unaffected
firefox95 --- wontfix
firefox96 --- fixed

People

(Reporter: marco, Assigned: marco)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

We went from around 65% to around 60%.

First bad is 6c01444e17210e96f5fb322c7b55a2e9f87ec0b0
Last good is 5a0ebbb0210fda2defe5a44a5b75f6f2488fe3c6

Drilling down to platform coverage, we can see it was Windows coverage which dropped.

In that range, there is https://hg.mozilla.org/mozilla-central/rev/04330041da3f and https://hg.mozilla.org/mozilla-central/rev/8f78ed673519de2dd9d88ef0e6ee7466eeeee667 who might be the cause of this.

The problem is the sccache disabling.

We use z:/build/build/src/ (https://searchfox.org/mozilla-central/rev/aa8c75b83f636948f708986173965c84cae8c25f/testing/mozharness/mozharness/mozilla/testing/codecoverage.py#130) as the prefix to remove from paths, but without sccache the paths are different (they are like Z:/task_163772669043488/build/src/js/src/vm/CodeCoverage.cpp).

Regressed by: 1712751
Assignee: nobody → mcastelluccio
Status: NEW → ASSIGNED
Summary: Investigate drop of code coverage on 25 October 2021 → Fix drop of code coverage on 25 October 2021

In a test task, I'd need to know the topsrcdir from the build.
I saw it is available in the target.mozinfo.json artifact from the build task. Is there an easy way to access this info from testing/mozharness/mozharness/mozilla/testing/codecoverage.py?
Do you see any other solution for me to know the topsrcdir in a test task?

Flags: needinfo?(jmaher)
Flags: needinfo?(gbrown)
Flags: needinfo?(ahal)

Set release status flags based on info from the regressing bug 1712751

mozinfo.find_and_update_from_json() tries to find a build environment with a mozinfo.json, but it's not very sophisticated -- I suspect that won't help in codecoverage.py. Similarly, the build system (and mach?) knows where topsrcdir is, but that's probably not of help in codecoverage.py

Hopefully :aryx's idea is helpful: https://searchfox.org/mozilla-central/rev/aa8c75b83f636948f708986173965c84cae8c25f/taskcluster/ci/perftest/linux.yml#11-16

I don't have a better suggestion.

Flags: needinfo?(gbrown)

could we add build_topsrcdir to mozinfo.json ?

We have access to topsrcdir here:
https://searchfox.org/mozilla-central/source/python/mozbuild/mozbuild/config_status.py#149

and would need to find a clean way to get add it in the write_mozinfo() function here:
https://searchfox.org/mozilla-central/source/python/mozbuild/mozbuild/mozinfo.py#147

Flags: needinfo?(jmaher)

Yeah sounds like Sebastian's suggestion of using a fetch (from comment 4) is the right approach. If you specify this config (ideally only in code coverage tasks), it would be available at $MOZ_FETCHES_DIR/target.mozinfo.json which the mozharness script could then access.

Flags: needinfo?(ahal)

Sorry forgot to cancel the needinfos, but yeah, Sebastian suggestion seems to be working well (I added the fetch to the test transform for ccov tasks).

Pushed by mcastelluccio@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/5b9c29148e81
Use topsrcdir from build task mozinfo.json instead of hardcoding the path for the gcov prefix. r=releng-reviewers,jmaher DONTBUILD
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 96 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: