简体   繁体   English

运行时错误:无法加载文件或程序集'Microsoft.Owin,版本= 3.0.0.0…Azure移动服务

[英]Runtime error: Could not load file or assembly 'Microsoft.Owin, Version=3.0.0.0…Azure mobile services

I have downloaded the ToDOService project from the Azure managementprotal after I created a Mobile service. 创建移动服务后,我已经从Azure管理门户下载了ToDOService项目。 Initially it had a lot of errors as the Nuget packages were outdated. 最初,由于Nuget包已过时,它有很多错误。 I Uninstalled the Azure mobile services .net backend package and its dependencies. 我卸载了Azure mobile services .net backend程序包及其依赖项。 Later I again installed all the packages manually and then I could build the project successfully. 后来,我再次手动安装了所有软件包,然后可以成功构建项目。 Somehow, when I run the service project I get this error:- 以某种方式,当我运行服务项目时,出现此错误:

Could not load file or assembly 'Microsoft.Owin, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Owin, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.

Source Error: 


Line 18: 
Line 19:             // Use this class to set WebAPI configuration options
Line 20:             HttpConfiguration config = ServiceConfig.Initialize(new ConfigBuilder(options));
Line 21: 
Line 22:             // To display errors in the browser during development, uncomment the following

Source File: ...\MyProject\MyService\App_Start\WebApiConfig.cs    Line: 20

My web.config looks like this 我的web.config看起来像这样

<dependentAssembly>
        <assemblyIdentity name="Microsoft.Owin" publicKeyToken="31bf3856ad364e35" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
      </dependentAssembly> 

I also tried to update the assembly to the latest, but could not be updated as Ver 3.0.1 is not compatible with its other dependencies. 我还尝试将程序集更新为最新版本,但由于版本3.0.1与它的其他依赖项不兼容而无法更新。

any help would be appreciated. 任何帮助,将不胜感激。 Thanks 谢谢

I have also experienced this issue, this blog post says that it happens when a SignalR or Web API application runs in a worker role. 我也遇到了这个问题, 这篇博客文章说,当SignalR或Web API应用程序以辅助角色运行时,就会发生这种情况。 For me, this error happens after I run a console app that is part of my solution...next time I try to access a web application in the project that uses Web API, I get the yellow screen of death. 对我来说,此错误是在运行作为解决方案一部分的控制台应用程序之后发生的...下一次,我尝试访问使用Web API的项目中的Web应用程序时,出现黄屏死机。

The fix mentioned in the blog post does not work, it appears your web.config has the correct version information specified. 博客文章中提到的修复程序不起作用,您的web.config似乎已指定了正确的版本信息。 It sounds like this is still an issue with the NuGet package. 听起来这仍然是NuGet包的问题。

We had similar issue, and apperantly by updating the Microsoft.Owin to the latest version (The time of writing this Version 3.0.1.0) solve the problem. 我们遇到了类似的问题,并且通过将Microsoft.Owin更新到最新版本(编写此版本3.0.1.0的时间)来解决该问题。

You can upgrade the package using package manager console, and type: "Install-Package Microsoft.Owin" 您可以使用程序包管理器控制台升级程序包,然后键入:“ Install-Package Microsoft.Owin”

Hope it helps. 希望能帮助到你。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 无法加载文件或程序集 Microsoft.Owin 3.0.0 到 3.0.1 - Could not load file or assembly Microsoft.Owin 3.0.0 to 3.0.1 无法加载文件或程序集“Microsoft.Owin,版本=3.0.1.0,文化=中性,PublicKeyToken=31bf3856ad364e35” - Could not load file or assembly 'Microsoft.Owin, Version=3.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' 无法加载文件或程序集“Microsoft.Owin,版本=2.1.0.0,文化=中性,PublicKeyToken=31bf3856ad364e35 - Could not load file or assembly 'Microsoft.Owin, Version=2.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 运行时错误:无法加载文件或程序集“System.Web.WebPages.Razor,版本=3.0.0.0” - Runtime error: Could not load file or assembly 'System.Web.WebPages.Razor, Version=3.0.0.0 无法加载文件或程序集 'Microsoft.Owin, Version=2.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' 或其依赖项之一 - Could not load file or assembly 'Microsoft.Owin, Version=2.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies 无法加载文件或程序集 'Microsoft.Extensions.Configuration.Abstractions,版本 = 3.0.0.0 - Could not load file or assembly 'Microsoft.Extensions.Configuration.Abstractions, Version=3.0.0.0 无法加载文件或程序集“System.Management.Automation,版本 = 3.0.0.0 - Could not load file or assembly 'System.Management.Automation, Version=3.0.0.0 无法加载文件或程序集“ Common.Logging,版本= 3.0.0.0” - Could not load file or assembly 'Common.Logging, Version=3.0.0.0' Microsoft.Owin.Host.SystemWeb 导致无法加载文件或程序集“System.Runtime” - Microsoft.Owin.Host.SystemWeb results in Could not load file or assembly 'System.Runtime 无法加载文件或程序集Microsoft.Owin.Security.OAuth,Version = 2.0.0.0 - Could not load file or assembly Microsoft.Owin.Security.OAuth, Version=2.0.0.0
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM