Bug 37251 - Can't build iOS project on build host even though it seems to be connected.
Summary: Can't build iOS project on build host even though it seems to be connected.
Status: RESOLVED DUPLICATE of bug 37600
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: XMA ()
Version: 4.0.0 (C6)
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2015-12-22 21:16 UTC by Jon Goldberger [MSFT]
Modified: 2016-01-13 05:06 UTC (History)
2 users (show)

Is this bug a regression?: ---
Last known good build:

Log files (145.83 KB, application/zip)
2015-12-22 21:16 UTC, Jon Goldberger [MSFT]

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Jon Goldberger [MSFT] 2015-12-22 21:16:33 UTC
Created attachment 14388 [details]
Log files

## Description

Although everything looks like the connection to the build host succeeds, when building a template iOS app from Visual Studio, the build stops immediately with a message like the following:

> Xamarin.VisualStudio.IOS.MonoTouchProjectProperties Error: 0 : [2015-12-22 15:11:24.5073] There was an error while trying to evaluate the consistency between local build and conencted Mac build.

Note this message is from the logs, but in the Output pane with Xamarin selected the message is similar but a bit different:

>The application App1 needs to be rebuilt due to an inconsistency between
>the connected Mac and the local app. Please rebuild the application and try

However rebuilding does not help. Also it is worth noting that the mtbs folder in ~/Library/Caches/Xamarin is never created. So there is no build on the Mac. 

I did a team viewer session with the customer who is experiencing this issue and could not find a cause. At one point there were messages about invalid SSH keys, so I removed all of the ssh keys on the Mac  in ~/.ssh/authorized_keys and ~/.ssh/known_hosts and restarted ssh on the Mac. This seemed to resolve the message about ssh keys but there was no change in the underlying behavior and still got the error noted above and still there was never an mtbs folder created in ~/Library/Caches/Xamarin.

## Steps to reproduce.

I have no steps to reproduce other than to remotely control the customer's computer and see for yourself. 

## Environment

Version info coming.
Comment 2 Brendan Zagaeski (Xamarin Team, assistant) 2015-12-22 21:41:47 UTC
## Note to whoever picks up the investigation on this

I get the "error while trying to evaluate the consistency" in the logs on my computer, and it doesn't cause any problems.

So I think that particular piece of information is not important.
Comment 3 Brendan Zagaeski (Xamarin Team, assistant) 2015-12-22 21:43:11 UTC
## Additional note to whoever picks up the investigation

On the other hand I _do not_ see the "needs to be rebuilt due to an inconsistency" message in the Output window, so that is a more interesting piece of information.
Comment 4 Jon Goldberger [MSFT] 2015-12-22 21:48:33 UTC
Version info:

=== Xamarin Studio ===

Version 5.10.1 (build 6)
Installation UUID: 3a39e627-0ebd-4865-b893-05917f15f670
Mono 4.2.1 (explicit/6dd2d0d)
GTK+ 2.24.23 (Raleigh theme)

Package version: 402010102

=== Xamarin.Profiler ===

Not Installed

=== Apple Developer Tools ===

Xcode 7.1.1 (9081)
Build 7B1005

=== Xamarin.iOS ===

Version: (Business Edition)
Hash: 7322991
Branch: master
Build date: 2015-12-08 16:20:29-0500

=== Xamarin.Android ===

Version: (Business Edition)
Android SDK: /Users/stuart/Library/Developer/Xamarin/android-sdk-mac_x86
Supported Android versions:
2.3 (API level 10)
4.0.3 (API level 15)
4.4 (API level 19)
6.0 (API level 23)

SDK Tools Version: 24.4.1
SDK Platform Tools Version: 23.0.1
SDK Build Tools Version: 23.0.1

Java SDK: /usr
java version "1.7.0_71"
Java(TM) SE Runtime Environment (build 1.7.0_71-b14)
Java HotSpot(TM) 64-Bit Server VM (build 24.71-b01, mixed mode)

=== Xamarin Android Player ===

Not Installed

=== Xamarin.Mac ===

Version: (Starter Edition)

=== Build Information ===

Release ID: 510010006
Git revision: 0b60eecdb531933734519c13257d16a780274aab
Build date: 2015-12-04 20:28:20-05
Xamarin addins: 9876fd7c9837977178411ec7375b4352c0a0d6af
Build lane: monodevelop-lion-cycle6-baseline

=== Operating System ===

Mac OS X 10.11.2
Darwin Dev-Mac-Mini.local 15.2.0 Darwin Kernel Version 15.2.0
Fri Nov 13 19:56:56 PST 2015
root:xnu-3248.20.55~2/RELEASE_X86_64 x86_64

visual studio

Microsoft Visual Studio Professional 2013
Version 12.0.40629.00 Update 5
Microsoft .NET Framework
Version 4.5.51209

Installed Version: Professional

LightSwitch for Visual Studio 2013 06177-004-0447006-02708
Microsoft LightSwitch for Visual Studio 2013

Team Explorer for Visual Studio 2013 06177-004-0447006-02708
Microsoft Team Explorer for Visual Studio 2013

Visual Basic 2013 06177-004-0447006-02708
Microsoft Visual Basic 2013

Visual C# 2013 06177-004-0447006-02708
Microsoft Visual C# 2013

Visual C++ 2013 06177-004-0447006-02708
Microsoft Visual C++ 2013

Visual F# 2013 06177-004-0447006-02708
Microsoft Visual F# 2013

Visual Studio 2013 Code Analysis Spell Checker 06177-004-0447006-02708
Microsoft® Visual Studio® 2013 Code Analysis Spell Checker

Portions of International CorrectSpell™ spelling correction system © 1993 by Lernout & Hauspie Speech Products N.V. All rights reserved.

The American Heritage® Dictionary of the English Language, Third Edition Copyright © 1992 Houghton Mifflin Company. Electronic version licensed from Lernout & Hauspie Speech Products N.V. All rights reserved.

Application Insights Tools for Visual Studio Package 1.0
Application Insights Tools for Visual Studio

ASP.NET and Web Tools 12.5.60612.0
Microsoft Web Developer Tools contains the following components:
Support for creating and opening ASP.NET web projects
Browser Link: A communication channel between Visual Studio and browsers
Editor extensions for HTML, CSS, and JavaScript
Page Inspector: Inspection tool for ASP.NET web projects
Scaffolding: A framework for building and running code generators
Server Explorer extensions for Microsoft Azure Web Apps
Web publishing: Extensions for publishing ASP.NET web projects to hosting providers, on-premises servers, or Microsoft Azure

ASP.NET Web Frameworks and Tools 2012.2 4.1.21001.0
For additional information, visit http://go.microsoft.com/fwlink/?LinkID=309563

ASP.NET Web Frameworks and Tools 2013 5.2.30612.0
For additional information, visit http://www.asp.net/

Common Azure Tools 1.4
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

Microsoft Azure Mobile Services Tools 1.4
Microsoft Azure Mobile Services Tools

NuGet Package Manager 2.8.60723.765
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

Office Developer Tools for Visual Studio 2013 ENU 12.0.40429
Microsoft Office Developer Tools for Visual Studio 2013 ENU

PHP Tools for Visual Studio 1.18.8429.2013
PHP Tools extend Visual Studio with a set of features to build PHP applications more efficiently. It makes code more readable, easier to navigate, and clean.

PreEmptive Analytics Visualizer 1.2
Microsoft Visual Studio extension to visualize aggregated summaries from the PreEmptive Analytics product.

SQL Server Data Tools 12.0.50318.0
Microsoft SQL Server Data Tools

Windows Phone 8.1 SDK Integration 1.0
This package integrates the tools for the Windows Phone 8.1 SDK into the menus and controls of Visual Studio.

Workflow Manager Tools 1.0 1.0
This package contains the necessary Visual Studio integration components for Workflow Manager.

Xamarin (1390b70)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin.Android (d300845)
Visual Studio plugin to enable development for Xamarin.Android.

Xamarin.iOS (ea30b32)
Visual Studio extension to enable development for Xamarin.iOS.
Comment 6 Brendan Zagaeski (Xamarin Team, assistant) 2016-01-13 05:06:24 UTC
After further study of the closely related Bug 36059, I have a fairly strong suspicion this bug has been a duplicate of that issue all along.

In particular, I see the tell-tale build warning in the original Desk case 240316 that started this bug:

> Could not authenticate the user using the existing ssh keys

I will accordingly mark this bug as a duplicate of Bug 37600. I have just recently filed that bug to track the precise problem where the "inconsistency" error arises as a consequence of the "could not authenticate ... existing ssh keys" warning.

If the original reporting customer is _no longer_ seeing the "existing ssh keys" warning in the build output (or error list), then attaching the latest diagnostic MSBuild output [1] to this bug report would be perfect. I will then inspect the diagnostic MSBuild output and reopen this bug as its own separate issue if needed.

Xamarin Customer Support

[1] http://developer.xamarin.com/guides/android/troubleshooting/troubleshooting/#Diagnostic_MSBuild_Output

(This document is listed under the Xamarin.Android section of the docs, but the steps are the same for Xamarin.iOS.)

*** This bug has been marked as a duplicate of bug 37600 ***