microsoft / MSBuildSdks

MSBuild project SDKs
MIT License
460 stars 82 forks source link

"error MSB3030: Could not copy the file" when using Microsoft.Build.CopyOnWrite #508

Open avivanoff opened 1 year ago

avivanoff commented 1 year ago

We have a solution that consists of 100+ projects, both managed and native. The source code and various package caches are located on the DevDrive. When building the solution, both from command line and from Visual Studio, we get random MSB3030 errors "Could not copy the file".

How do I go about figuring out the root of the problem? Can I produce a detailed log that will be helpful for you to analyze?

erikmav commented 12 months ago

The CoW package includes low-priority logging that becomes visible when using -verbosity:diag that might help.

erikmav commented 12 months ago

Also be sure you are using the latest package - a recent large commit aligned the Copy task code in CoW more closely with the underlying code from MSBuild. For some users this corrected some outstanding problems and allowed committing the SDK update.

avivanoff commented 12 months ago

@erikmav, we are using Microsoft.Build.CopyOnWrite 1.0.282.

Using v=diag did not help much, unless I am not looking for the right thing. I can send you the log privately if that would help.

erikmav commented 12 months ago

@avivanoff Sure, send to my username at Microsoft dot com

avivanoff commented 12 months ago

@erikmav, logs are sent. Let me know if they went through.