gpt4 book ai didi

c# - 无法解决 .NET Framework 的包错误,版本 = v4.5.1

转载 作者:太空宇宙 更新时间:2023-11-03 15:19:03 25 4
gpt4 key购买 nike

我正在努力将我的 ASP.NET RC1 项目转换为 Core.NET RC2。打开项目时,包还原失败并出现以下错误:

Errors in C:\Users\user\Documents\cwc_scaffold\project\CWC.xproj Unable to resolve 'Glimpse (>= 2.0.0-beta1)' for '.NETFramework,Version=v4.5.1'. Unable to resolve 'SharpGIS.NmeaParser (>= 1.5.1)' for '.NETFramework,Version=v4.5.1'.

我对 ASPNuget 还很陌生,所以我不太确定这些错误是什么意思。

编辑:这是我的 project.json 文件:

{
"version": "0.9.0",
"buildOptions": {
"emitEntryPoint": true,
"preserveCompilationContext": true,
"copyToOutput": [
"appsettings.json"
]
},
"tooling": {
"defaultNamespace": "COIN.Monitor"
},
"dependencies": {
"Microsoft.AspNetCore.Diagnostics": "1.0.0-rc2-final",
"Microsoft.AspNetCore.Server.IISIntegration": "1.0.0-rc2-final",
"Microsoft.AspNetCore.Mvc": "1.0.0-rc2-final",
"Microsoft.AspNetCore.Mvc.TagHelpers": "1.0.0-rc2-final",
"Microsoft.AspNetCore.Server.Kestrel": "1.0.0-rc2-final",
"Microsoft.AspNetCore.StaticFiles": "1.0.0-rc2-final",
"Microsoft.EntityFrameworkCore.Tools": {
"version": "1.0.0-preview1-final",
"type": "build"
},
"Microsoft.Extensions.Configuration.FileExtensions": "1.0.0-rc2-final",
"Microsoft.Extensions.Configuration.Json": "1.0.0-rc2-final",
"Microsoft.Extensions.Logging": "1.0.0-rc2-final",
"Microsoft.Extensions.Logging.Console": "1.0.0-rc2-final",
"Microsoft.Extensions.Logging.Debug": "1.0.0-rc2-final",
"Microsoft.EntityFrameworkCore.Sqlite": "1.0.0-rc2-final",
"Microsoft.AspNetCore.Identity.EntityFrameworkCore": "1.0.0-rc2-final",
"Glimpse": "2.0.0-beta1",
"Serilog": "1.5.14",
"Microsoft.Tpl.Dataflow": "4.5.24",
"Microsoft.AspNetCore.Hosting.WindowsServices": "1.0.0-rc2-final"
},
"frameworks": {
"net451": {
"frameworkAssemblies": {
"System.Web": "4.0.0.0"
}
}
},
"commands": {
"web": "Microsoft.AspNetCore.Server.Kestrel"
},
"tools": {
"Microsoft.AspNetCore.Razor.Tools": {
"version": "1.0.0-preview1-final",
"imports": "portable-net45+win8+dnxcore50"
}
},
"publishOptions": {
"include": [
"wwwroot",
"Views",
"appsettings.json",
"web.config"
],
"exclude": [
"node_modules"
]
},
"scripts": {
"prepublish": [
"gulp clean",
"gulp deploy-client",
"webpack"
],
"prebuild": [
"npm run pre-build"
],
"postpublish": [
"dotnet publish-iis --publish-folder %publish:OutputPath% --framework %publish:FullTargetFramework%"
]
}
}

最佳答案

从 Nuget 中提取的包将默认为依赖包/库获取最低 公分母版本。

可能(?)您需要上述软件包的更高版本?

因此,查看已安装包的 nuget 页面和每个单独的打包包,检查它们是否是可以安装的新版本或将依赖行为更改为 Highest或其他有意义的设置。

无论如何,您可能需要对引入的包进行试验以使其正常工作。

enter image description here

关于c# - 无法解决 .NET Framework 的包错误,版本 = v4.5.1,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37928812/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com