Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Including a tool causes assembly conflicts. #2370
What You Are Seeing?
When I include the tool for Cake.Squirrel
along with my own custom addin that depends on System.IO.Compression I end up getting a MissingMethodException for the System.IO.Compression.ZipFile.OpenRead method. I believe there is a known historical problem with that function missing from the net46 dll. Somehow including that tool (which is a C# nuget package with assembly references for integrating squirrel with a .net app along with the exe's) messes with the assembly resolution when running the script.
if I remove that tool directive I can execute the ZipFile.OpenRead function but then the cake.squirrel calls error because the tool is missing. I suppose I can move the tool installation to the bootstrapper but I also thought I heard the plan was to not need the bootstrapper in the future?
What is Expected?
I expect tools to just download and install the exes in the tools directory and not reference the assemblies. If I wanted those I would list it as an addin.
What version of Cake are you using?
Are you running on a 32 or 64 bit system?
What environment are you running on? Windows? Linux? Mac?
Are you running on a CI Server? If so, which one?
How Did You Get This To Happen? (Steps to Reproduce)
The first paragraph describes my problem.
By inspecting your log it doesn't seem like
I don't understand what you mean by "lets code come further".
As for the absense of Cake.Squirrel. Cake.CustomAddin references Cake.Squirrel as a nuget package. Not sure if that is acceptable but we are writing an addin to make it easy to do some builds internally that require squirrel so it made sense to reference the other addin directly in a common a function. Thus far we haven't had any issues doing so. Except for the conflict with the
I was able to work around the problem by adding Squirrel.Windows to the tools' directory package.config file. Which leads me to believe that cake does in fact do some sort of extra execution/reference when loaded by that directive.