phillipsj / Cake.AzureStorage

Cake Addin for working with Azure Storage
Apache License 2.0
6 stars 10 forks source link

System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.WindowsAzure.Storage, Version=6.2.0.0, #5

Closed dzenand closed 7 years ago

dzenand commented 8 years ago

Error: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.WindowsAzure.Storage, Version=6.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. File name: 'Microsoft.WindowsAzure.Storage, Version=6.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' at Cake.AzureStorage.AzureStorage.DeleteBlobsByPrefix(AzureStorageSettings settings) at Submission#0.DeleteBlobsByPrefix(AzureStorageSettings settings) at Submission#0.<.ctor>b__16() at Cake.Core.ActionTask.Execute(ICakeContext context) at Cake.Core.DefaultExecutionStrategy.Execute(CakeTask task, ICakeContext context) at Cake.Core.CakeEngine.ExecuteTask(ICakeContext context, IExecutionStrategy strategy, Stopwatch stopWatch, CakeTask task, CakeReport report) at Cake.Core.CakeEngine.RunTarget(ICakeContext context, IExecutionStrategy strategy, String target) at Cake.Scripting.BuildScriptHost.RunTarget(String target) at Submission#0..ctor(Session session, Object& submissionResult) at Submission#0.(Session session) at Roslyn.Scripting.CommonScriptEngine.Execute[T](String code, String path, DiagnosticBag diagnostics, Session session, Boolean isInteractive) at Roslyn.Scripting.Session.Execute(String code) at Cake.Core.Scripting.ScriptRunner.Run(IScriptHost host, FilePath scriptPath, IDictionary`2 arguments) at Cake.Commands.BuildCommand.Execute(CakeOptions options) at Cake.CakeApplication.Run(CakeOptions options) at Cake.Program.Main()

WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value HKLM\Software\Microsoft\Fusion!EnableLog to 1. Note: There is some performance penalty associated with assembly bind failure logging. To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

phillipsj commented 8 years ago

@dzenand @JRKelso Have you included configured the Azure Storage Nuget package to install as part of your cake file? Cake has changed a lot recently and we will be updating this and the examples to aid in configuration.

dzenand commented 8 years ago

@phillipsj I followed the example I have added #addin Cake.AzureStorage on top of the cake file. Do i need to pull some additional nuget packages?

jonathanstowell commented 7 years ago

Did anyone ever manage to work this out? With the latest package I get a similar error but for Microsoft.WindowsAzure.Storage 7.2.1.0

phillipsj commented 7 years ago

Yes I believe I have. I will make sure the fix gets pushed up. I apologize for the delay.

On Monday, November 7, 2016, Jonathan Stowell notifications@github.com wrote:

Did anyone ever manage to work this out? With the latest package I get a similar error but for Microsoft.WindowsAzure.Storage 7.2.1.0

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/RadioSystems/Cake.AzureStorage/issues/5#issuecomment-258965341, or mute the thread https://github.com/notifications/unsubscribe-auth/ABfthd4cqWsNKFW8lrFMc1ZyCsvoO1eLks5q75VrgaJpZM4JPwx5 .

jonathanstowell commented 7 years ago

Thanks,

Is there anything I can do to help or is there a workaround I can use to get this running? I find it odd this was last release on the 10th of October on nuget but doesn't work with the newer Cake packages. I'm using the latest Cake "0.16.2".

Apologizes for the lack of understanding around the problem, if needs be I can pull the source and start debugging myself, but if you've solved it, it makes life easier ;-)

JRKelso commented 7 years ago

@jonathanstowell You might try to do

r "tools/Addins/WindowsAzure.Storage/lib/net40/Microsoft.WindowsAzure.Storage.dll"

as a workaround temporarily to get it functioning and see the file. Right now I'm trying to get the latest version tested against our stuff to see if we can get this working out the box like it should, although all my attempts have failed so far to get it to automatically reference the file. @phillipsj may have to see if he can figure it out this evening if I don't get this resolved soon.

phillipsj commented 7 years ago

@jonathanstowell @JRKelso I have discovered the issue. Some depedencies got out of sync with the Azure Storage dll.

phillipsj commented 7 years ago

@jonathanstowell @JRKelso That was the issue, the dependencies got out of sync with the Azure Storage library, strong typing got to like it. Please start using version 0.9.45.

jonathanstowell commented 7 years ago

@phillipsj Ah cool, I actually managed to get this working by cloning the repo, building it locally and referencing the dll directly.

I have made a change locally which allows me to use the local emulator as the CloudStorageAccount has a static profile to connect to a local emulator.

When I get a chance I'll fork make these changes and submit a pull request.