android - DevOpS 无法构建 Xamarin 应用程序
问题描述
我有一个 Xamarin 应用程序(Windows 和 Android)。它编译运行。但是,当我尝试在 DevOps 中构建它时,我收到如下所示的错误。我不知道如何解决它,希望有任何帮助谢谢
C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\bin\msbuild.exe "C:\Users\VssAdministrator\AppData\Local\Temp\NuGetScratch\gepi4ll2.pci.nugetinputs.targets" /t:GenerateRestoreGraphFile /nologo /nr:false /v:q /p:NuGetRestoreTargets="C:\Users\VssAdministrator\AppData\Local\Temp\NuGetScratch\ak3xdawe.wl0.nugetrestore.targets" /p:RestoreTaskAssemblyFile="C:\hostedtoolcache\windows\NuGet\4.4.1\x64\nuget.exe" /p:RestoreSolutionDirectory="D:\a\9\s" /p:RestoreConfigFile="D:\a\9\Nuget\tempNuGet_10.config" /p:SolutionDir="D:\a\9\s"
NuGet.CommandLine.ExitCodeException: Exception of type 'NuGet.CommandLine.ExitCodeException' was thrown.
at NuGet.CommandLine.MsBuildUtility.<GetProjectReferencesAsync>d__6.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at NuGet.CommandLine.RestoreCommand.<GetDependencyGraphSpecAsync>d__48.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at NuGet.CommandLine.RestoreCommand.<DetermineInputsFromMSBuildAsync>d__43.MoveNext()
##[error]The nuget command failed with exit code(1) and error(C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(725,2): error XA0000: Could not determine API level for $(TargetFrameworkVersion) of 'v10.0'. [D:\a\9\s\App1.Android\MyApp.Android.csproj])
##[error]Packages failed to restore
解决方案
推荐阅读
- amazon-web-services - 尝试安装 AWS Elastic Beanstalk 获取:ObjectNotFound: (C:\Users\Ameer:String) [], CommandNotFoundException
- javascript - 如何在 NodeJS 中使用 fs 删除扩展名未知的文件?
- prometheus - prometheus federation 集群数据同步逻辑
- python - ModuleNotFoundError 尽管在 VSCode 中安装了软件包并选择了正确的解释器
- chisel - 使用带有命名空间机制的 chisel3?
- javascript - 使用 Javascript 和 Web 音频 API 流式传输 Icecast 音频和元数据
- firebase - 颤振尝试安装软件包
- swiftui - 如何使用“AudioServicesPlayAlertSoundWithCompletion”重复播放系统声音并产生振动?
- opencv - 如何在 opencv 的 yolov3 和 yolov4 之间正确转换?
- javascript - 防止仅对组件的一部分进行状态更新时重新渲染