c# - 没有注册类型 'Microsoft.Framework.Runtime.ILibraryManager' 的服务

标签 c# asp.net .net asp.net-core

我目前正在做一个关于新版 ASP.NET 的项目。当我运行一个新的空 ASP.NET 项目时,我遇到了这个非常烦人的错误。除了生成的代码之外,项目中没有其他任何东西......我尝试更改 CLR,但没有任何帮助。

我收到这个错误:


Server Error in '/' Application.

No service for type 'Microsoft.Framework.Runtime.ILibraryManager' has been registered.

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.InvalidOperationException: No service for type 'Microsoft.Framework.Runtime.ILibraryManager' has been registered.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[InvalidOperationException: No service for type 'Microsoft.Framework.Runtime.ILibraryManager' has been registered.]
System.Web.HttpRuntime.HostingInit(HostingEnvironmentFlags hostingFlags, PolicyLevel policyLevel, Exception appDomainCreationException) +303

[HttpException (0x80004005): No service for type 'Microsoft.Framework.Runtime.ILibraryManager' has been registered.]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +9940016 System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +101 System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +261

---------------------------------------------------------------------- I'm running the 1.0.0beta5 clr x64 on windows 8.1.

有人知道如何解决这个错误吗?

最佳答案

当我在谷歌上搜索“Microsoft.Framework.Runtime.ILibraryManager”时,我在 github 中发现了几个提到该错误的问题。这听起来像是当你有不匹配的包时发生的,即如果你仍然在 project.json 中列出一些 beta4 包

关于c# - 没有注册类型 'Microsoft.Framework.Runtime.ILibraryManager' 的服务,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31270565/

相关文章:

c# - 简单地在 C# 中比较两个对象的属性

asp.net - 在 ASP.NET 中,我将如何将屏幕分成四个相等的矩形?

.net - winforms 应用程序中的查询设计器

c# - 不带对话框的 IHTMLDocument2 打印

c# - 使用 MAF 加载程序集的正确方法

C#从反序列化的json对象中获取值

c# - 通信对象,System.ServiceModel.Channels.ServiceChannel,不能用于通信

c# - OWIN 中间件可以使用 http session 吗?

c# - ICollection - 获取单个值

.net - .net 的匹配器库