修复错误 NU1605 的正确方法是什么:检测到包降级 - log4net [英] What is the right way to fix error NU1605: Detected package downgrade - log4net

查看:61
本文介绍了修复错误 NU1605 的正确方法是什么:检测到包降级 - log4net的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请按以下步骤操作:

dotnet new console
dotnet add-package log4net --version 2.0.8
dotnet publish -r win10-x64

然后你得到:

error NU1605: Detected package downgrade: System.Runtime.InteropServices from 4.3.0 to 4.1.0.

您可以修复它,将以下内容添加到您的属性组下的 csproj

You can fix it adding the following to your csproj under PropertyGroup

<NoWarn>$(NoWarn);NU1605</NoWarn>

但我想了解解决此问题的正确方法.

But I'd like to understand the right way to get this fixed.

推荐答案

不幸的是,除了包所有者升级他们的引用或在 csproj 中添加条款之外别无选择.有关详细信息,请参阅此 GitHub 问题:https://github.com/dotnet/core/issues/907

Unfortunately, there's no other option than the package owner to upgrade their references or you adding the clausule in the csproj. Please see this GitHub issue for more information: https://github.com/dotnet/core/issues/907

这篇关于修复错误 NU1605 的正确方法是什么:检测到包降级 - log4net的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆