ASP.NETCORE安装/更新包会产生兼容性错误

时间:2017-04-15 23:17:09

标签: asp.net asp.net-core .net-core sendgrid

我有一个ASP.NETCORE Web应用程序,我正在尝试使用visual studio在其上安装SendGrid包,但是它给出了一个错误,指出一个或多个包与.NETCoreAPP不兼容,版本= v1.1 。 然后我注意到当前的包有可用的更新,我试图更新当前的包,但它仍然给了我同样的错误。

这是错误消息:

Package Microsoft.Composition 1.0.27 is not compatible with netcoreapp1.1 
(.NETCoreApp,Version=v1.1). Package Microsoft.Composition 1.0.27 supports: 
portable-net45+win8+wp8+wpa81 (.NETPortable,Version=v0.0,Profile=Profile259)
One or more packages are incompatible with .NETCoreApp,Version=v1.1.

这是我的project.json文件:

{
"Netcoreapp1.0": {

"dependencies": {
  "Microsoft.NETCore.App": {
    "type": "default",
    "version": "1.1.0"
  },
  "MySql.Data.EntityFrameworkCore": "7.0.6-ir31",
  "BundlerMinifier.Core": "2.2.306",
  "Microsoft.ApplicationInsights.AspNetCore": "2.0.0",
  "Microsoft.AspNetCore.Diagnostics": "1.1.0",
  "Microsoft.AspNetCore.Mvc": "1.1.0",
  "Microsoft.AspNetCore.Razor.Tools": "1.1.0-preview4-final",
  "Microsoft.AspNetCore.Routing": "1.1.0",
  "Microsoft.AspNetCore.Server.IISIntegration": "1.1.0",
  "Microsoft.AspNetCore.Server.IISIntegration.Tools": "1.1.0-preview4-final",
  "Microsoft.AspNetCore.Server.Kestrel": "1.1.0",
  "Microsoft.AspNetCore.StaticFiles": "1.1.0",
  "Microsoft.Extensions.Configuration.EnvironmentVariables": "1.1.0",
  "Microsoft.Extensions.Configuration.Json": "1.1.0",
  "Microsoft.Extensions.Logging": "1.1.0",
  "Microsoft.Extensions.Logging.Console": "1.1.0",
  "Microsoft.Extensions.Logging.Debug": "1.1.0",
  "Microsoft.Extensions.Options.ConfigurationExtensions": "1.1.0",
  "Microsoft.VisualStudio.Web.BrowserLink.Loader": "14.1.0",
  "Microsoft.EntityFrameworkCore.SqlServer": "1.0.1",
  "Pomelo.EntityFrameworkCore.MySql": "1.1.1-prerelease-10016",
  "Microsoft.NETCore.Runtime.CoreCLR": "1.1.0",
  "Microsoft.AspNetCore.Identity.EntityFrameworkCore": "1.1.0",
  "Microsoft.AspNetCore.Authentication.Cookies": "1.1.0"
},

"tools": {
  "Microsoft.AspNetCore.Razor.Tools": {
    "version": "1.1.0-preview4-final",
    "imports": "portable-net45+win8+dnxcore50"
  }
},

"buildOptions": {
  "emitEntryPoint": true,
  "preserveCompilationContext": true
},

"Frameworks": {
  "Net461": {},
  "Netcoreapp1.0": {
    "Dependencies": {
      "Microsoft.NETCore.App": {
        "Version": "1.0.1"
      }
    },
    "Imports": "dnxcore50"
  }
},
"runtimes": {
  "win7-x64": {},
  "ubuntu.14.04-x64": {}
},

"publishOptions": {
  "include": [
    "wwwroot",
    "**/*.cshtml",
    "appsettings.json",
    "web.config"
  ]
}
}
}

我对这一点非常陌生,也是一般的编程新手。如果您需要查看项目中的更多文件,请告诉我。 谢谢!

0 个答案:

没有答案