简体   繁体   English

C# uwp 应用程序未在发布模式下构建

[英]C# uwp application not building in release mode

I'm trying to build my application in release mode but it's not working.我正在尝试以发布模式构建我的应用程序,但它不起作用。 Debug works fine.调试工作正常。 The error I get is:我得到的错误是:

STDERR: ERROR: The asynchronous operation was failed: The package could not be installed because a higher version of this package is already installed (hresult_error:80073D06)[location] = c:\buildagent\work\bfdcd5891b5bc64\resharperautomationtools\native\solution\winrt_launcher\src\utility.hpp(41)[function] = void __cdecl jbrs::wait_for_finished(const struct winrt::com_ptr<struct IAsyncInfo> &)[package name] = Microsoft.NET.Native.Runtime.1.7[uri] = C:\Program Files (x86)\Microsoft SDKs\UWPNuGetPackages\microsoft.net.native.compiler\1.7.6\tools\Runtime\x64\Microsoft.NET.Native.Runtime.1.7.appx

These are the windows sdks这些是windows sdks

 <TargetPlatformVersion Condition=" '$(TargetPlatformVersion)' == '' ">10.0.18362.0</TargetPlatformVersion>
 <TargetPlatformMinVersion>10.0.15063.0</TargetPlatformMinVersion>

This is the uwp version这是uwp版本

<PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform">
      <Version>6.2.10</Version>
</PackageReference>

I'm unable to figure out how to fix it and was unable to find anything else on the internet.我无法弄清楚如何修复它,也无法在互联网上找到任何其他内容。 Would appreciate it if someone could help.如果有人可以提供帮助,将不胜感激。

Update (Fixed it)更新(已修复)

I was able to fix it by downgrading uwp to 5.2.8.我能够通过将 uwp 降级到 5.2.8 来修复它。 (Using Rider) I did it by going to the NuGet Tab and then selecting the second item in the context menu. (使用 Rider)我通过转到 NuGet 选项卡,然后在上下文菜单中选择第二项来完成此操作。

在此处输入图片说明

After that I also had to downgrade the project by clicking on the button next to the button with the red line.之后,我还必须通过单击带有红线的按钮旁边的按钮来降级项目。

在此处输入图片说明

Update (Fixed it)更新(已修复)

I was able to fix it by downgrading uwp to 5.2.8.我能够通过将 uwp 降级到 5.2.8 来修复它。 (Using Rider) I did it by doing going to the NuGet Tab and then selecting the second item in the context menu. (使用 Rider)我通过转到 NuGet 选项卡,然后在上下文菜单中选择第二项来做到这一点。

在此处输入图片说明

After that I also had to downgrade the project by clicking on the button next to the button with the red line.之后,我还必须通过单击带有红线的按钮旁边的按钮来降级项目。

在此处输入图片说明

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM