GetPathsOfAllDirectoriesAbove() cannot be evaluated after updating .Net Framework version (4.6.2 to 4.7.2)

霸气de小男生 提交于 2019-12-25 01:12:24

问题


A project I have been working on was upgraded from .NET Framework 4.6.2 to 4.7.2. On build, in a file that is not my code, I get the following error:

I also see the same error in the build tab of my project properties.

[

I'm at a loss- I've searched for the error and am coming up empty. Has anyone encountered and/or resolved this before?


回答1:


Looks like after upgrading your build tool is changed from MSBUILD to Roslyn. Microsoft.Managed.Core.targets is Roslyn target file.

if you have following Nuget packages installed:

  • Microsoft.CodeDom.Providers.DotNetCompilerPlatform

  • Microsoft.Net.Compilers

Then possibly it's causing the issue. Upgrade the Microsoft.CodeDom.Providers.DotNetCompilerPlatform to 2.x and remove the second one. That should fix the issue.



来源:https://stackoverflow.com/questions/59276192/getpathsofalldirectoriesabove-cannot-be-evaluated-after-updating-net-framewor

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!