gpt4 book ai didi

azure - 无法使用 NuGet 安装 Microsoft.Azure.ServiceBus

转载 作者:行者123 更新时间:2023-12-03 02:53:28 25 4
gpt4 key购买 nike

我正在运行测试 .Net Core 控制台应用程序来尝试使用 ServiceBus 消息。但是,在使用 Nuget 安装 Microsoft.Azure.ServiceBus v3.1.1 后,出现以下错误

Package Microsoft.Azure.ServiceBus 3.1.1 is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1). Package Microsoft.Azure.ServiceBus 3.1.1 supports: netstandard2.0 (.NETStandard,Version=v2.0)

我尝试安装到 v3.3.0 并得到相同的结果,我正在使用最新的 .Net 框架并更新了我的 VS2017,所以我不知道问题是什么。还有其他人遇到过这个问题吗?

最佳答案

I don't know what the problem can be

无论 Microsoft.Azure.ServiceBus 包的版本是 v3.1.1 还是 v3.3.0它们都依赖项是 .NETStandard 2.0,而您的应用程序是 .NetStandard 1.0。因此,正如 Peter 所说,您拥有的 .net core 版本太旧了。

您可以去下载最新的. Net Core SDK然后重新安装你想要的包。

或者您可以下载Microsoft.Azure.ServiceBus v1.0.0。但由于版本太旧,部分功能可能没有。因此,我建议您可以将 TargetFramework 更新到 .net core 2.0+。

关于azure - 无法使用 NuGet 安装 Microsoft.Azure.ServiceBus,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54630481/

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