I decided to install NCrunch today to evaluate it. However I ran into a problem almost right away. NCrunch does not build the projects in my solution.
I have projects that reference assemblies on a (substed) drive that contains external assemblies. Somehow this causes an exception in NCrunch on build:
System.IO.IOException: File path must be absolute with disk root: F:Some.External.Assembly.dll
at nCrunch.Common.IO.FilePath..ctor(String #==, Boolean #==)
at nCrunch.Common.IO.FilePath.FromAbsolutePath(String absoluteFilePath)
at System.Linq.Enumerable.WhereSelectArrayIterator`2.MoveNext()
at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at nCrunch.Common.IO.DirectoryPath.GetFiles(String wildcardSpec)
at nCrunch.Common.IO.FilePath.GetRelatedFiles()
at nCrunch.Client.ComponentLoader.SnapshotComponentFactory.#=(ComponentBuildAnalysisResult #===)
at nCrunch.Client.ComponentLoader.SnapshotComponentFactory.#==(ProcessorArchitecture #==)
at nCrunch.Client.ComponentLoader.SnapshotComponentFactory.CreateSnapshotComponentFromXml(FilePath projectFilePath, BuildXml projectXml, FilePath solutionFilePath, String[] additionalFilesToIncludeAtSolutionLevel, Boolean isLoadedFromFile, ISnapshotConfig snapshotConfig, VisualStudioVersion vsVersion)
I would expect the file path to be F:\Some.External.Assembly.dll. Can I work around this somehow?
Thanks in advance for your assistance.
Build/Test Issues
NCrunch fails to build when reference is on another drive
Started by Mousy on 8,125 views
Remco NCrunch Developer
#5117
24 Jan 2014 07:09 UTC
Hi, thanks for posting and for giving NCrunch a try!
Would you be able to submit a bug report straight after you've had this happen to you? You can do this from inside the NCrunch menu. The bug report will contain useful information for reproducing and fixing the issue.
To work around the problem, I recommend subst-ing your external assemblies from one level further up - so that the DLLs are not situated in the root directory of F drive. This should allow you to get past the exception.
Cheers,
Remco
Would you be able to submit a bug report straight after you've had this happen to you? You can do this from inside the NCrunch menu. The bug report will contain useful information for reproducing and fixing the issue.
To work around the problem, I recommend subst-ing your external assemblies from one level further up - so that the DLLs are not situated in the root directory of F drive. This should allow you to get past the exception.
Cheers,
Remco
I have made the simplest test case possible: 1 assembly in the root of a drive and one project with a reference to this assembly. The same error occurs. I have submitted a bug report right after this.
I moved the assembly into a sub directory and NCrunch builds just fine. So your assessment seems correct.
Sadly moving all references to a sub directory is not an option for my actual projects. There are hard dependencies on the specific location, and changing all that would be a major headache...
I moved the assembly into a sub directory and NCrunch builds just fine. So your assessment seems correct.
Sadly moving all references to a sub directory is not an option for my actual projects. There are hard dependencies on the specific location, and changing all that would be a major headache...
Remco NCrunch Developer
#5119
24 Jan 2014 09:29 UTC
I saw the bug report come through. This is perfect. Thanks!
This is a high priority fix and it will be in the next build. I'm expecting the next build to be the RTM of V2 which will be out within the next 2 weeks. NCrunch V1 doesn't use the same file path translation system, so you might be able to get your solution working with this version if you're prepared to downgrade for a week or so.
Thanks again for the detailed analysis of this issue.
This is a high priority fix and it will be in the next build. I'm expecting the next build to be the RTM of V2 which will be out within the next 2 weeks. NCrunch V1 doesn't use the same file path translation system, so you might be able to get your solution working with this version if you're prepared to downgrade for a week or so.
Thanks again for the detailed analysis of this issue.
With version 2.4 the build issue is gone. I can now start my evaluation on our actual product.
Remco NCrunch Developer
#5169
31 Jan 2014 07:58 UTC
Great to hear. Thanks for taking the time to report the issue. It was good to get the fix into the RTM.
Post a reply
Log in to reply.