c# - 包 X 与 netcoreapp3.1 不兼容

标签 c# .net visual-studio .net-core nuget

我正在尝试在 VS 2019 中运行我的 .net core 3.1 项目,但在构建过程中出现如下错误。

Severity Code Description Project File Line Suppression State Error NU1202 Package System.Diagnostics.DiagnosticSource 4.5.0 is not compatible with netcoreapp3.1 (.NETCoreApp,Version=v3.1). Package System.Diagnostics.DiagnosticSource 4.5.0 does not support any target frameworks. WebApi.Base C:\Users\ilyas.varol.TEST\source\repos\performancemanagementprojects\WebApi.Base\WebApi.Base.csproj


笔记:
  • 我重新安装了所有软件包和 .net core 3.1 sdk
  • 同一项目正在另一台计算机上运行

  • 更新
    我还没有解决我的问题。因此,我想用屏幕截图详细说明我的问题。我希望有一个人可以帮助我。
    错误列表
    enter image description here
    Nuget 包管理器 > 整合
    enter image description here

    最佳答案

    一、clean nuget caches或删除C:\Users\xxx(current user)\.nuget\packages下的所有文件.
    然后,删除 binobj文件夹。
    重新构建项目以再次测试。

    关于c# - 包 X 与 netcoreapp3.1 不兼容,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/66149874/

    相关文章:

    c# - Resharper 的 "Type argument is redundant"和断言存在问题

    c++ - 如何在没有 Python 调试库的情况下在 Debug模式下使用 Cmake/Visual Studio 构建 OpenCV

    C2065 我所有的 for 循环都出现错误

    c# - 根据选定的网格行项目检索隐藏对象属性 C#

    c# - 更新到 Automapper v5 时出现 .NullSubstitute 错误

    c# - 可以找到错误 CS1061 “...Does Not Contain Definition and No Extension Method...accepting a first argument of type ”

    c# - 多 channel GroupBy() 如何比单 channel 更快?

    c# - 从 C# 应用程序上的文件加载字体

    c# - 秒的格式是什么 XXXXXXX.XXXXX :XXX (Win32_NetworkLoginProfile)

    c# - MVC4 : Compilation Error The type 'System.Data.Objects.DataClasses.EntityObject' is defined in an assembly that is not referenced