[triage] upstream#7417: Code coverage build fails to instrument file in use
Upstream: dotnet#7417
Status: COMPLETE
Classification: bug-report
Confidence: 0.90
Reproduced: ⏭️ Skipped (CI infrastructure issue — not reproducible locally)
Area: Core
Investigated at: 2026-03-07
Triage Summary
Category: Bug Report
Reasoning: The issue describes a reproducible CI build failure where code coverage instrumentation (likely OpenCover or a similar tool) throws "Unable to instrument module" because Microsoft.ML.TestFramework.pdb is locked by another process during the Windows x64 Debug build. This is a legitimate defect in the build/test pipeline — a file-locking race condition during parallel test execution or code coverage collection. It is tagged as "Known Build Error" and "blocking-clean-ci" by a Microsoft team member.
Summary: During the Windows_x64 / Windows_x64 Build_Debug / Run All Tests CI leg, the code coverage tool fails to instrument a module because Microsoft.ML.TestFramework.pdb is being held open by another process. The issue was created as a known-issue tracking entry so the Azure DevOps build analysis system can correlate future hits. The hit report shows the issue recurred at least once (linked to PR dotnet#7582).
Suggested Labels: bug
Reproduction Results
Reproduction was skipped because this is a CI/build infrastructure race condition that only manifests in Azure DevOps pipelines under Windows x64 with code coverage enabled. It cannot be reliably reproduced via a standalone dotnet run project.
Error Pattern (from issue body):
Unable to instrument module
The process cannot access the file .*\Microsoft.ML.TestFramework.pdb because it is being used by another process.
Root Cause Analysis:
The code coverage instrumentation tool (e.g., OpenCover or Coverlet) attempts to rewrite or read the PDB file for Microsoft.ML.TestFramework while another process (likely a concurrent test runner or the test host itself) still holds an open handle to it. This is a timing/locking race in the CI pipeline — parallel test jobs or test host teardown may not release the PDB handle before the coverage pass begins. Relevant test framework source lives in src/Microsoft.ML.TestFramework/ and the build/coverage configuration in eng/.
Generated by Triage Single Issue · ◷
[triage] upstream#7417: Code coverage build fails to instrument file in use
Upstream: dotnet#7417
Status: COMPLETE
Classification: bug-report
Confidence: 0.90
Reproduced: ⏭️ Skipped (CI infrastructure issue — not reproducible locally)
Area: Core
Investigated at: 2026-03-07
Triage Summary
Category: Bug Report
Reasoning: The issue describes a reproducible CI build failure where code coverage instrumentation (likely OpenCover or a similar tool) throws "Unable to instrument module" because
Microsoft.ML.TestFramework.pdbis locked by another process during the Windows x64 Debug build. This is a legitimate defect in the build/test pipeline — a file-locking race condition during parallel test execution or code coverage collection. It is tagged as "Known Build Error" and "blocking-clean-ci" by a Microsoft team member.Summary: During the
Windows_x64 / Windows_x64 Build_Debug / Run All TestsCI leg, the code coverage tool fails to instrument a module becauseMicrosoft.ML.TestFramework.pdbis being held open by another process. The issue was created as a known-issue tracking entry so the Azure DevOps build analysis system can correlate future hits. The hit report shows the issue recurred at least once (linked to PR dotnet#7582).Suggested Labels: bug
Reproduction Results
Reproduction was skipped because this is a CI/build infrastructure race condition that only manifests in Azure DevOps pipelines under Windows x64 with code coverage enabled. It cannot be reliably reproduced via a standalone
dotnet runproject.Error Pattern (from issue body):
Root Cause Analysis:
The code coverage instrumentation tool (e.g., OpenCover or Coverlet) attempts to rewrite or read the PDB file for
Microsoft.ML.TestFrameworkwhile another process (likely a concurrent test runner or the test host itself) still holds an open handle to it. This is a timing/locking race in the CI pipeline — parallel test jobs or test host teardown may not release the PDB handle before the coverage pass begins. Relevant test framework source lives insrc/Microsoft.ML.TestFramework/and the build/coverage configuration ineng/.