dotnet / dotnet/project-system

BuildAcceleration: Incorrect files copied when DisableTransitiveProjectReferences is true

Open
#9,757 1 comment 0 reactions 1 assignee Claimed by @drewnoakes View on GitHub
Feature-Build-Acceleration
Dominant language
C#
Stars
1k
Forks
415
PR merge metrics
No merged PRs in 30d

Description

## Visual Studio Version
17.14.12

## Summary
When `DisableTransitiveProjectReferences` is enabled BuildAcceleration will copy more files to the output than a call to msbuild does.
Msbuild does **not** copy transitive dependencies that are not referenced statically in the dependency graph of the direct dependencies when `DisableTransitiveProjectReferences` is enabled . When build acceleration is enabled these files get copied anyways

## Steps to Reproduce

1. Clone my repo: https://github.com/janthomasQS/BuildAccelerationRepro
2. Build the solution with VS. the first build will consider all projects out of date and call msbuild for all of them
3. Observe the build output of `BuildAccelRepro.csproj` : `IndirectDependency.dll` does **not** exist in the output
4. Build another time in VS
5. VS will now copy `IndirectDependency.dll` into the output of `BuildAccelRepro.csproj`

## Expected Behavior
Build acceleration should copy the same files as a call to msbuild does.

## Actual Behavior
More files are copied.

## User Impact
Using BuildAcceleration changes the build output result and might therefore change behaviour.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.