Search Unity

Build and Run - builds, but not running

Discussion in 'iOS and tvOS' started by edwon, Jan 25, 2021.

  1. edwon

    edwon

    Joined:
    Apr 24, 2011
    Posts:
    266
    Hi,

    Everytime I hit "build and run" in Unity for iOS, it's building and opening Xcode (in which I had previously selected my build device) but it's simply not doing the "Run" part of "build and run".

    this is really annoying as I have to wait for builds to finish in Xcode, then hit play in Xcode and wait again

    iteration time extremely slow

    please help! Anybody know how I can get this working again?
     
  2. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,792
    Build and run support has been super spotty over the years, I treat it as if it doesn't exist these days. I understand this isn't the answer you are looking for.
     
  3. robertas-unity

    robertas-unity

    QA Minion Unity Technologies

    Joined:
    Mar 24, 2015
    Posts:
    29
    Hi @edwon!

    Could you give some more details about this - which Unity version are you using? Which Xcode version are you using? If you have more than one Xcode version installed, are they all detected in Unity ('Run In Xcode' dropdown in the 'Build Settings' window)? Any other details you think might be useful - let us know, we'll try to investigate.
     
  4. edwon

    edwon

    Joined:
    Apr 24, 2011
    Posts:
    266
    Unity 2020.2.1f1 (but it's happening in any Unity version I believe, it seems that updating the OS to Catalina is when it started for me)
    Xcode 12.4 (but was happening with previous versions of Xcode as well)
    only one version of Xcode installed and yes It is detected by unity

    I have no idea what else could be causing this
     
  5. edwon

    edwon

    Joined:
    Apr 24, 2011
    Posts:
    266
    Is there any news on this? I was so desperate to get this working I reinstalled osx from scratch, no luck. Somebody help!
     
  6. JeffDUnity3D

    JeffDUnity3D

    Joined:
    May 2, 2017
    Posts:
    14,446
    In the meantime, you can certainly just Build, then open in Xcode and deploy. Granted not the best solution, but will allow you to build and test your game. This is how I develop for iOS personally.
     
  7. edwon

    edwon

    Joined:
    Apr 24, 2011
    Posts:
    266
    Wow most unhelpful reply of the year award.

    I am already doing this! Do you think if I was willing to reinstall my OS to try to fix this, that I was happy with that as a solution? As a Unity employee, why would you have a feature in Unity that you are simply willing to put up with not working?

    The issue is that when I hit Build and Run, it should do both those things, but right now, it only does one of them, Build. It then opens Xcode, but it doesn’t run.

    The reason this is soul crushing, is that it wastes a ton of time. I have to stare at the screen for a few minutes while Unity builds, wait for it, then open that in Xcode, select the device, press play in there, wait, and then finally it’s on my phone (I make AR apps so testing on the phone is often irreplaceable, and yes I use the AR Foundation Remote plugin but it doesn’t cover all test cases, nothing is as good as a build on the real device for certain tests/tasks)

    This little ritual can cost far more than the build time, waiting etc... what often happens is I’ll try to start doing something else during the first step, read documentation or code, and then got lost in that, and forget what I was even building the phone version for. Repeat this 20 or 50 times a day and it results in incredible inefficiency. It feels like a miracle when I finally get a build on the phone and remember what I was testing.

    Android builds pretty much always work perfectly with Build and Run (I realize that it’s easier because they don’t have to go through Xcode, but still, build and run used to work fine on iOS, my feeling is that the latest MacOS probably messed it up with all its permissions needing)

    Is there no way to debug Build and Run? Can I somehow see under the hood when Unity has its little blue bar up? Can you have an engineer at Unity actually try to fix this?
     
    Last edited: Apr 2, 2021
    kloogens likes this.
  8. edwon

    edwon

    Joined:
    Apr 24, 2011
    Posts:
    266
    Is there any movement on this?!!
     
  9. JeffDUnity3D

    JeffDUnity3D

    Joined:
    May 2, 2017
    Posts:
    14,446
    I believe you missed or misunderstood my comment "In the meantime..."
     
  10. kloogens

    kloogens

    Joined:
    Jul 1, 2015
    Posts:
    116

    I feel your pain.
    I ran into the same issue with my android build. At first, it built and ran, then it didn't then it did and so on.

    I looked at the Android device and saw it only had about 700 MB of storage space available.

    I removed the 3.6 gig Go pro app to free up some space and now it is building and running okay.

    I really hope your issue was/is this easy.