Bug 37613 - Failed to start iOS Simulator in the mac
Summary: Failed to start iOS Simulator in the mac
Status: RESOLVED DUPLICATE of bug 38695
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: iOS ()
Version: 4.0.0 (C6)
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2016-01-12 13:28 UTC by softlion
Modified: 2016-03-01 23:16 UTC (History)
7 users (show)

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

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:
Status:
RESOLVED DUPLICATE of bug 38695

Description softlion 2016-01-12 13:28:37 UTC
Hi,
i have an issue with VS2015.

It compiles and deploys ok on ios simulator on mac for some time. And suddenly it won't anymore.
Xamarin Log shows this error:


Xamarin.Messaging.Client.MessagingClient Error: 0 : [2016-01-12 14:22:01.2660] An error occured on client vs10428benja while executing a post for topic xvs/idb/4.0.1.60/show-app
System.TimeoutException: The operation has timed out.
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at Xamarin.Messaging.Client.MessagingClient.<PostAsync>d__2`2.MoveNext()
Xamarin.Messaging.Client.MessagingClient Error: 0 : [2016-01-12 14:22:01.5540] Failed to start iOS Simulator in the mac
Xamarin.Messaging.Exceptions.MessagingException: An error occured on client vs10428benja while executing a post for topic xvs/idb/4.0.1.60/show-app ---> System.TimeoutException: The operation has timed out.
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at Xamarin.Messaging.Client.MessagingClient.<PostAsync>d__2`2.MoveNext()
   --- End of inner exception stack trace ---
   at Xamarin.Messaging.Client.MessagingClient.<PostAsync>d__2`2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Xamarin.Messaging.Client.MessagingClient.<PostAsync>d__1`2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Xamarin.Messaging.Client.MessagingClient.<PostAsync>d__5`2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at Xamarin.Messaging.Client.IMessagingClientExtensions.Execute[T](Func`1 postFunction)
   at Xamarin.Messaging.Client.IMessagingClientExtensions.Post[TRequest,TResponse](IMessagingClient client, TRequest message, Boolean retain, Int32 timeoutSecs)
   at Xamarin.VisualStudio.IOS.IMessagingServiceExtensions.<>c__DisplayClass0.<ShowApplication>b__1() in C:\Users\builder\data\lanes\2696\7082690b\source\XamarinVS\src\Core\VisualStudio.IOS\Extensions\IMessagingServiceExtensions.cs:line 38


My network is stable, so what's the problem ?
Ty!



Microsoft Visual Studio Professional 2015
Version 14.0.24720.00 Update 1
Microsoft .NET Framework
Version 4.6.01038

Installed Version: Professional

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

ASP.NET and Web Tools 2015 (RC1 Update 1)   14.1.11120.0
ASP.NET and Web Tools 2015 (RC1 Update 1)

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

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

Azure App Service Tools v2.8.1   14.0.11123.0
Azure App Service Tools v2.8.1

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

DataFactoryProject   1.0
Microsoft Data Factory Package

GitHub.VisualStudio   1.0
A Visual Studio Extension that brings the GitHub Flow into Visual Studio.

JetBrains ReSharper Ultimate 10.0.2   Build 104.0.20151218.120627
JetBrains ReSharper Ultimate package for Microsoft Visual Studio. For more information about ReSharper Ultimate, visit http://www.jetbrains.com/resharper. Copyright © 2016 JetBrains, Inc.

Microsoft Azure Data Factory Node Node   1.0
Azure Data Factory extension for Visual Studio Server Explorer.

Microsoft Azure HDInsight HQL Service   2.0.2900.0
Language service for Hive query

Microsoft Azure HDInsight Tools for Visual Studio   2.0.2900.0
An integrated development environment for HDInsight application development.

Microsoft Azure Mobile Services Tools   1.4
Microsoft Azure Mobile Services Tools

Microsoft Azure Tools   2.8
Microsoft Azure Tools for Microsoft Visual Studio 2015 - v2.8.31121.1

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

Open Command Line   2.0.162
Opens a command line at the root of the project. Support for all consoles such as CMD, PowerShell, Bash etc.

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

SQL Server Data Tools   14.0.50730.0
Microsoft SQL Server Data Tools

TypeScript   1.7.4.0
TypeScript for Microsoft Visual Studio

Visual Studio Tools for Universal Windows Apps   14.0.24720.00
The Visual Studio Tools for Universal Windows apps allow you to build a single universal app experience that can reach every device running Windows 10: phone, tablet, PC, and more. It includes the Microsoft Windows 10 Software Development Kit.

VSColorOutput   2.1.1
Color output for build and debug windows - http://mike-ward.net/vscoloroutput

Web Essentials 2015   1.0.203
Adds many useful features to Visual Studio for web developers.

Xamarin   4.0.1.60 (7082690)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin.Android   6.0.1.5 (50280e4)
Visual Studio plugin to enable development for Xamarin.Android.

Xamarin.iOS   9.4.1.10 (53922f8)
Visual Studio extension to enable development for Xamarin.iOS.


=== MAC


=== Xamarin Studio ===

Version 5.10.2 (build 49)
Runtime:
	Mono 4.2.2 (explicit/7b87787)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 402020010

=== Xamarin.Profiler ===

Not Installed

=== Apple Developer Tools ===

Xcode 7.2 (9548)
Build 7C68

=== Xamarin.iOS ===

Version: 9.4.1.12 (Business Edition)
Hash: 78c6cd3
Branch: master
Build date: 2015-12-17 18:29:42-0500

=== Xamarin.Android ===

Not Installed

=== Xamarin Android Player ===

Not Installed

=== Xamarin.Mac ===

Not Installed

=== Xamarin Inspector ===

Version: 0.3.2.3
Hash: 1b526e6
Branch: master
Build date: Tue Nov 17 20:54:30 UTC 2015

=== Build Information ===

Release ID: 510020049
Git revision: deed4cd240ff3611c8742bbc62296e207f46173d
Build date: 2015-12-17 11:13:36-05
Xamarin addins: 8bd975e7b465f6fe812b64d736f3b7e8c1a79a3e
Build lane: monodevelop-lion-cycle6-c6sr1

=== Operating System ===

Mac OS X 10.11.2
Darwin Mac-de-minimac.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
Comment 1 softlion 2016-01-13 07:15:59 UTC
Workaround 1: (work at 100%)

- open the xamarin "IDB.exe" log file on the mac.
- find the last command it executes, copy it
- run it manually to launch the app in the simulator successfully 100% of the time. 
If you rebuild the app in VS, it will always launch the last built version. That's cool.


Workaround 2: (work at 50%)

- kill the app in the simulator. The new app version will then deploy and run fine immediatly.

Workaround 3: (work at 50% because of other bugs)

- Close VS and kill the remaining IDB.exe process on the mac. Reopen VS. If the list of simulators fills correctly, you are lucky. Otherwise close VS again.
Comment 2 softlion 2016-01-13 14:09:14 UTC
Workaround 4: 

- quit the ios simulator. It will relaunched almost immediatly with the deployed app ok.
Comment 3 softlion 2016-01-13 15:39:23 UTC
In fact i missed a thing in Workaround 1: the command line that launch the simulator is visible in the process list as a blocked process, not in the IDB.exe log.

/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/bin/mtouch --launchsim /Users/iben/Library/Caches/Xamarin/mtbs/builds/AcTouch/0474c03676f2e668b505fa1650dfe185/bin/iPhoneSimulator/Debug/AcTouch.app --device=:v2:udid=62CEF8C6-DE24-6AC8-958F-1B0D48A6949D -stdout /Users/iben/Library/Caches/Xamarin/mtbs/builds/AcTouch/0474c03676f2e668b505fa1650dfe185/out.log -stderr /Users/iben/Library/Caches/Xamarin/mtbs/builds/AcTouch/0474c03676f2e668b505fa1650dfe185/err.log -argument=-connection-mode -argument=none --sdkroot /Applications/Xcode.app/Contents/Developer -sdk 9.2


When run manually, it correctly opens the simulator and launch the app. A small line is displayed beside:

Starting iPhone 5s - iOS 9.2
Press enter to terminate the application
>

Hope it helps.
Comment 4 Brendan Zagaeski (Xamarin Team, assistant) 2016-03-01 23:16:13 UTC
Thanks for the report. I will mark this as a duplicate of another bug that was filed recently for the same problem and by chance has had a bit more activity.

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