Forum Visual Studio
We are excited to announce that the Xamarin Forums are moving to the new Microsoft Q&A experience. Q&A is the home for technical questions and answers at across all products at Microsoft now including Xamarin!

We encourage you to head over to Microsoft Q&A for .NET for posting new questions and get involved today.

Multiple attempts needed to deploy to an iOS emulator

ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

I have to do Command+Enter multiple times so that the app can be deployed and run on any iOS emulator. The deployment fails and with each attempt it progresses and finally deploys and runs. That appears to be some timeout issue.

Once the app is loaded to the emulator, it can be run even without the debugger attached.

I have XS 5.5.2, Xamarin.IOS, Xcode 6.0.1 and my MBP (mid 2010 mode) is running OS X 10.9.5.

Does anyone else have similar issue? Any workaround?

Best Answer


  • voidvoid DKBeta ✭✭✭
    edited October 2014

    I see this regularly as well. I'm currently using the beta channel on a freshly installed Yosemite.

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    Today morning I got updates to Xcode 6.1 (6604) and to Xamarin.iOS But these updates have not resolved this issue. Moreover now I am not able to deploy to the iPhone 6 iOS 8.1 simulator. I don't know which update is an issue.

  • JeffreyStedfastJeffreyStedfast USXamarin Team Xamurai

    The issue isn't with Xamarin.iOS, the bug deploying to the iOS simulator for 8.1 is a bug in Xamarin Studio that I've already fixed and should end up making it into Xamarin Studio 5.5.3.

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭
    edited November 2014

    @JeffreyStedfast‌ Got XS 5.5.3. But I am still not able to deploy to any of the simulators of Xcode 6.

  • JeffreyStedfastJeffreyStedfast USXamarin Team Xamurai

    What error are you getting?

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    The following is what I see in Application Output window..

    Process exited with code 69, command:
    xcrun -sdk macosx otool -L /Users/shantimohan/Dropbox/XPAs/PretzoldsEx/cp019_NoteTaker9_XFP/iOS/bin/iPhoneSimulator/Debug/

    Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo.

    Starting iPhone 4s
    Launching application
    Application launched. PID = 16110
    Press enter to terminate the application
    Application Terminated

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @JeffreyStedfast‌ Yes, that worked. When I started Xcode, it first asked to accept terms and then installed some components. Then the magic worked. ThanQ...

  • rogiheerogihee NLMember ✭✭✭

    Still running into this issue, even after having XCode opened on XS 5.5.3 build 6, and iOS (stable). I'm on X 10.9.5.

    It worked exactly one time, and after that I now consistently get the message "Could not connect to debugger". Restarting XCode or the simulator does not work.

  • rogiheerogihee NLMember ✭✭✭

    Disabling incremental builds for debug configuration fixed it.....

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @jstedfast‌ This is happening again.

    I checked on @rogihee‌ tip. The option 'Enable incremental builds' is already unchecked. But now again back to square one. It doesn't deploy on any number of runs. It just ran only 2 or 3 times successfully after I ran the Xcode.

  • JeffreyStedfastJeffreyStedfast USXamarin Team Xamurai

    If you clean your build and then rebuild, does that work?

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    That is not helping. In one app it is failing in Main.cs -> calling AppDelegate. In another it is same as before, just it is terminated.

    I only have OS Maveriks, Is that be a reason?

  • RDRD USMember

    HI @jstedfast‌,

    I've the same problem and usually clean and build fix it, but after a while it happens again...

    My2cents :)


  • RolfBjarneKvingeRolfBjarneKvinge USXamarin Team Xamurai

    Can you create a screencast to show exactly what happens and how it fails?

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @RolfBjarneKvinge‌, I will take sometime to prepare the screencast. I don't know if @RD‌ can provide one on what one is experiencing.

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @RolfBjarneKvinge‌ Sorry for the inordinate delay. Here is the link for screencast of the problem that I am facing.

    In this video the iOS emjulator responded for the 2nd run itself. But till last week I had to run several times. Few times, I gave up running the app for iOS as it was crashing whatever I do.

    There were some updates to Xcode and Xamarin. So the current versions that I have are: Xamarin Studio 5.5.4 (build 15), Xcode 6.1.1 (6611), Xamarin.iOS (Indie Edition).

  • RolfBjarneKvingeRolfBjarneKvinge USXamarin Team Xamurai

    In the iOS 8+ simulators there is a 20s timeout for the app to launch (this is the same timeout that the app has on the device to launch), this is probably why the app terminates at launch.

    However it does not explain why the app takes this long to launch in the first place; does it usually take a while (even when it works)?

    Could you get the simulator's system log from a failed launch attempt (you can open the system log from the menu Debug -> Open System Log)?

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @RolfBjarneKvinge‌ Sorry, my MBP is having issues with the HDD. It fills up fast and now I am left with one 400+MB (??!!??). Online forums are suggesting clean installing the OS. May be I will have to take it to Genius bar. So I will try it once it is resolved and post the logs if the issue still present. May be clean OS install is the solution for my iOS simulator issue (???).

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @RolfBjarneKvinge‌ Thanks for waiting. OK my Mac issues were resolved and I ran the iOS project. Of course the launch failed again. But I couldn't locate the menu Debug -> Open System Log. You meant it on a XS on MacBook Pro?

  • JeffreyStedfastJeffreyStedfast USXamarin Team Xamurai

    I think Rolf meant the Help -> Open Log Directory menu item and not Debug.

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @RolfBjarneKvinge‌ and @jstedfast‌ : Here are the 3 log files that I found with the date on which I ran the iOS project without success. Hope this helps to find solution to my issue

  • RolfBjarneKvingeRolfBjarneKvinge USXamarin Team Xamurai

    @ShantimohanElchuri‌: I meant Debug -> Open System Log from the iOS Simulator, not Xamarin Studio.

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    @RolfBjarneKvinge‌ Here I am attaching two files. The 'iOS Simulator Log' contains very old entries. I don't know if 'system.log' will be of any use. I see only this file contained latest entries.

    Let me know if you can make anything out of these. As such now I created a new project, after the latest updates, and it also doesn't run.

  • RolfBjarneKvingeRolfBjarneKvinge USXamarin Team Xamurai

    @ShantimohanElchuri‌: there's nothing very interesting in those logs, so this is quite strange.

    Can you launch successfully with Xcode?

  • ShantimohanElchuriShantimohanElchuri USMember ✭✭✭✭✭

    It's an Xamarin Forms project. Can it be launched with Xcode? If so, how do I?

Sign In or Register to comment.