Repository navigation
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5782 +/- ##
==========================================
- Coverage 76.13% 76.11% -0.02%
==========================================
Files 528 528
Lines 19579 19579
Branches 3829 3829
==========================================
- Hits 14906 14903 -3
- Misses 3791 3793 +2
- Partials 882 883 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
The Windows .NET legs spend about 12 minutes in Setup Environment and Restore, against about 4.5 on Linux. On the Windows images, setup-dotnet installs into C:\Program Files\dotnet, where the SDK installs workloads as MSI packages, and NuGet extracts packages into the user profile on C:. The workload step takes 5.6 minutes there, against about 2 on macOS and Linux, which install more workloads. This installs .NET and the NuGet cache next to the workspace, where workloads install as plain files. On the x64 runners that also moves them to D:, and on the arm64 runners they stay on C:, so the two legs separate the install mode from the drive. Windows also stops restoring the Android test app, which its solution filters exclude. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ric-oliv
force-pushed
the
ci/windows-dotnet-on-workspace-drive
branch
from
October 23, 2026 13:57
a32a458 to
137ca28
Compare
This was referenced Oct 23, 2026
The arm64 Windows runners have no D: drive, so .NET and the NuGet packages stayed on C:, and the win-arm64 leg kept a 4 to 5 minute restore. A probe ran the leg's steps with them and TEMP on a Dev Drive, and the job took 33.0 minutes twice, against 40.0 and 44.3 without it. Restore, build and the integration tests each got 2 to 4 minutes faster. Turning off Defender's real-time scanning saved less, because the image already excludes C:\ from it. The step moves into a composite action, because the MSBuild job uses it too. That job's workspace is on D:, but its restore ran in the user profile on C: and took 8.8 minutes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A second probe ran the win-arm64 leg's steps three ways in one run. With only the NuGet packages and TEMP on the Dev Drive, the job took 33.8 and 32.4 minutes. With .NET there too, it took 36.9, and with nothing there 37.2 and 35.8. Installing every SDK onto the new drive made Setup Environment slower than it saved. In one of those jobs, `fsutil devdrv trust` failed with "Access is denied" because the new volume was still in use, and that failed the job. Trust is now retried, and if it still fails the step only warns, because the Dev Drive is a speedup. The antivirus setting now comes before the drive exists, since it only applies to volumes mounted after it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The two Windows
.NETlegs are tied with macOS as the slowest jobs in the build workflow, and about 12 minutes of each goes to Setup Environment and Restore. Linux does the same work in about 4.5.From the logs of run 39858273561:
setup-dotnettakes 97 to 108 seconds on Windows, against 24 to 31 on macOS and Linux.C:\Program Files\dotnet. About 2 of those minutes restore the Android test app, which the Windows solution filters exclude.Restoretakes 4.8 to 5.3 minutes, against about 1. NuGet extracts the packages into the user profile onC:.This PR is an experiment to find out which of those matters:
D:, where the workspace already is. win-arm64 has noD:, so there they stay onC:.Measured on two runs of this PR, against the median of 7
mainruns from October 22 and 23:mainRun 1's logs, against run 39858273561, answer the question:
setup-dotnetwent from 97 to 53 seconds and Restore from about 5 minutes to 1 only on win-x64, where the files moved toD:. So the drive is what made those two slow.maui-windowsandwasm-toolsworkloads, and the build still passes without them.win-arm64 stayed the slower Windows leg, because its runner has no
D:.A Dev Drive on win-arm64
A probe, #5798, ran the win-arm64 leg's steps four ways, twice each. These are whole-job minutes, with the unit tests in the foreground:
mainC:\andD:\from Defender, which is why turning off real-time scanning saved little.C:.So when the workspace is on
C:, which today is only win-arm64, the step now creates a Dev Drive and puts the NuGet packages and TEMP on it. .NET goes next to the workspace on every Windows runner, as before.The step moved into a
windows-dotnet-drivecomposite action, because the MSBuild job uses it too. That job's workspace is onD:, but its restore ran in the user profile onC:and took 8.8 minutes in #5796.Measured on this run, against the 5 runs of the other CI PRs from the same evening, which don't have this change. For the MSBuild job that's 4 runs, leaving out #5796, which adds
-m.Run MSBuildstepmsbuild.exeresolved the .NET SDK fromD:\a\sentry-dotnet\.dotnetand nothing fromC:\Program Files, so Visual Studio's MSBuild works with .NET next to the workspace.C:The last layout is the fastest, so .NET stays next to the workspace now.
fsutil devdrv trustfailed with "Access is denied" because the volume was still in use, and that failed the job. The step now retries trust, and if it still fails it only warns, because the Dev Drive is a speedup. The antivirus setting now comes before the drive exists, since it only applies to volumes mounted after it.The first run's iOS Device Tests failure was the known flaky integration retry, and its rerun passed.
#skip-changelog