2

我的所有项目都没有在我的 Azure DevOps MacOS 构建主机上构建失败。它是一个自托管的构建主机。突然,我的项目在尝试构建时抛出了这个错误:

error MSB4018: The "GenerateDepsFile" task failed unexpectedly.
error MSB4018: System.MissingMethodException: Method not found: System.Collections.Generic.IList`1<NuGet.Packaging.Core.PackageDependency> NuGet.ProjectModel.LockFileTargetLibrary.get_Dependencies()

我发现这个 GitHub 问题看起来很相似,但发布的解决方案对我没有帮助: https ://github.com/mono/mono/issues/13537

As mentioned in xamarin/xamarin-android#3155 this is caused by a version mismatch in nuget between msbuild and dotnet core. The solution is to update your dotnet core install to the latest stable version

我已经安装了最新的 .NET Core,并更新了 Visual Studio for Mac,但是问题仍然存在。

另一个信息:当我从我的 Windows 机器和相同的 MacOS 构建主机构建相同的 Xamarin.iOS 项目时,应用程序构建得很好。但我猜这个过程可能会有所不同。

4

1 回答 1

1

今天再次更新 Visual Studio for Mac 和 .NET Core SDK 似乎已经解决了这个问题。

于 2019-06-15T19:34:21.750 回答