Windows build failure: System.IO.DirectoryNotFoundException: Could not find a part of the path 'F:\Agent\_work\2\s\artifacts\win10-x86\corehost\locked\dotnet.exe'
Windows build failing in VSO
[TARGET <] [FAIL] [00:01:41.808] CompileStage1 (Microsoft.DotNet.Cli.Build.CompileTargets.CompileStage1) 2016-04-28T17:27:54.8758491Z Build failed: System.IO.DirectoryNotFoundException: Could not find a part of the path 'F:\Agent_work\2\s\artifacts\win10-x86\corehost\locked\dotnet.exe'. 2016-04-28T17:27:54.8758491Z at System.IO.Win32FileSystem.CopyFile(String sourceFullPath, String destFullPath, Boolean overwrite) 2016-04-28T17:27:54.8758491Z at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite) 2016-04-28T17:27:54.8758491Z at System.IO.File.Copy(String sourceFileName, String destFileName, Boolean overwrite) 2016-04-28T17:27:54.8758491Z at Microsoft.DotNet.Cli.Build.CompileTargets.CopySharedHost(String outputDir) in F:\agent_work\2\s\scripts\dotnet-cli-build\CompileTargets.cs:line 463 2016-04-28T17:27:54.8758491Z at Microsoft.DotNet.Cli.Build.CompileTargets.CompileStage1(BuildTargetContext c) in F:\agent_work\2\s\scripts\dotnet-cli-build\CompileTargets.cs:line 324 2016-04-28T17:27:54.8758491Z at Microsoft.DotNet.Cli.Build.Framework.BuildContext.ExecTarget(BuildTarget target) in F:\agent_work\2\s\scripts\Microsoft.DotNet.Cli.Build.Framework\BuildContext.cs:line 144 2
@schellap I think this is related to your changes.
cc @piotrpMSFT
@Sridhar-MS should we pull out dotnet/cli#2636 to unblock the builds assuming its related?
Flip variabled Dirs.CoreHostLocked to be same as Dirs.CoreHost.
The change dotnet/cli#2636 required a change in VSO build definition too because of introduction of a new target RestoreLockedCoreHost. After adding this target to VSO build definition I am no longer seeing the above exception.
I am also looking into how to minimize these kind of breaking changes to VSO build defintions.
Awesome, thanks for the investigation. Would it make sense to have a targets file which we can edit in the repo with a list of targets to do task X and not in the build definition?