Our process was using Nuget.exe latest version. We had to move back to previous version to get this resolved.
Invalid static method invocation syntax: "[MSBuild]::VersionLessThanOrEquals('$(TargetFrameworkVersion)', '2.0')". Method '[MSBuild]::VersionLessThanOrEquals' not found.
Hi Team, I have made code changes and everything is working as expected in locally but when i try to run same code in Azure DevOps pipeline getting build error.
Here is the following error I got. Please help is something need to update in Azure DevOps
C:\Windows\ServiceProfiles\NetworkService.nuget\packages\microsoft.extensions.apidescription.server\6.0.5\build\Microsoft.Extensions.ApiDescription.Server.targets(5,38): error MSB4186: Invalid static method invocation syntax: "[MSBuild]::VersionLessThanOrEquals('$(TargetFrameworkVersion)', '2.0')". Method '[MSBuild]::VersionLessThanOrEquals' not found. Static method invocation should be of the form: $([FullTypeName]::Method()), e.g. $([System.IO.Path]::Combine(a
, b
)). Check that all parameters are defined, are of the correct type, and are specified in the right order.