Skip to content

Enable content copying transitive in VS.#14256

Closed
ocallesp wants to merge 1 commit intodotnet:masterfrom
ocallesp:fix/issue/4923_MSBuildCopyContentTransitively
Closed

Enable content copying transitive in VS.#14256
ocallesp wants to merge 1 commit intodotnet:masterfrom
ocallesp:fix/issue/4923_MSBuildCopyContentTransitively

Conversation

@ocallesp
Copy link
Copy Markdown
Contributor

@ocallesp ocallesp commented Oct 21, 2020

The problem:
Currently Fast-up-date (FUTD) cannot resolve CopyToOutputDirectory transitively.

Lets assume there is project A and has a reference to B and B has a reference to C.
If C contains items with CopyToOutputDirectory, and if those items are modified, then project A will not detect those changes.
Bug dotnet/project-system#4665

The fix for the issue 4665 is in the pr 6046 in dotnet ProjectSystem, but this changes will cause conflicts with dependencies of _SplitProjectReferencesByFileExistence . This pr 6046 in dotnet ProjectSystem executes targets that has dependencies with AssignProjectConfiguration. The problem is that dotnet will consume the output generated by those dependencies before AssignProjectConfiguration is executed. This causes AssignProjectConfiguration to consume no data. More details in here.

What this change does:
Set MSBuildCopyContentTransitively to true which means transitive copying content.

How this change help to solve the dependencies:
MSBuildCopyContentTransitively = true means transitive copying content. ProjectSystem and AssignProjectConfiguration will have their own copy of the content.

This change is not high priority.

This is needed to fix the Fast up-to-date to check
CopyToOutputDirectory items from project references
dotnet/project-system#4665

More details on MSBuildCopyContentTransitively in
dotnet/msbuild#4865
@ocallesp ocallesp requested review from a team and AntonLapounov as code owners October 21, 2020 01:57
Copy link
Copy Markdown
Member

@sfoslund sfoslund left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already defaulted MSBuildCopyContentTransitively to true in this PR #12318, so this shouldn't be needed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants