Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Build failed for no clear reason

Discussion in 'Unity Cloud Build' started by jwvanderbeck, Oct 26, 2019.

  1. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    34: No Library cache found - ALL assets will be re-imported.
    35: + Detected last used Unity version: 2019.2.9f1
    36: + Detecting Unity installation ...
    37: + Building with Unity installed at /UNITY_PATH/Unity/macos/published/Unity-2019_2_10f1/Unity.app/Contents/MacOS/Unity
    38: ! build of 'windows-alpha' failed. undefined method `[]' for nil:NilClass

    That is pretty much the extent of the FULL LOG that the build gave which is pretty useless, and gives no clear reason for the failure.

    One thing that DOES seem odd though is this is supposed to be a WINDOWS build yet unless I'm misreading that log it is using a Mac version of Unity to build?

    EDIT: I have two build targets one for Mac and one for Windows, and they both failed with no indication of why and they both built using this same MacOs version. I don't know if that last bit is normal or not. My previous builds have mostly all been good so never looked that closely.
     
    Last edited: Oct 26, 2019
  2. hasbean

    hasbean

    Joined:
    Mar 26, 2013
    Posts:
    2
    I'm having the same issue. iOS, Android, and WebGL are all failing with the same error.
     
  3. massonetto

    massonetto

    Joined:
    May 2, 2018
    Posts:
    1
    Same error here

    32: + Detected last used Unity version: 2019.2.5f1
    33: + Detecting Unity installation ...
    34: + Building with Unity installed at /UNITY_PATH/Unity/macos/published/Unity-2019_2_10f1/Unity.app/Contents/MacOS/Unity
    35: ! build of 'default-android' failed. undefined method `[]' for nil:NilClass
     
  4. Otto_Oliveira

    Otto_Oliveira

    Joined:
    Jul 24, 2014
    Posts:
    33
    Yeah, for me too. However, I'm using Unity 2018.4
    That error seems to start happening a few hours ago
     
  5. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    Well this isn't good. And on a weekend no less when us indies do the most work :D
     
  6. Otto_Oliveira

    Otto_Oliveira

    Joined:
    Jul 24, 2014
    Posts:
    33
    Just solved it, changing the Config to:
    Unity version: Auto Detect Version
     
  7. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    What version of the editor are you using?

    In my case I'm using the same version that is being used on UCB (19.2.10) so I'm not sure that will matter, though I will try it. I suspect 2019.2.10, being rather new, is misconfigured on UCB.
     
  8. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    Yeah looks like the problem is with the recently added 2019.2.10. Building with 19.2.9 hasn't finished yet but seems to be working as it has already gotten farther along than the failed ones did.

    EDIT Did complete successfully on 2019.2.9
     
    Last edited: Oct 26, 2019
  9. IOU_RAY

    IOU_RAY

    Joined:
    Jul 25, 2017
    Posts:
    53
    Same, 2018.x....

    Hate to be anyone else during prime time.
     
  10. DebugLogError

    DebugLogError

    Joined:
    Jul 24, 2013
    Posts:
    41
    We're also encountering this. Enabling "Auto Detect Version" did not resolve the issue.
     
  11. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    Which local version of the editor are you using? Rolling back to 2019.2.9 fixed it for me.
     
  12. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    Yeah. I filed a support ticket, but haven't had a response yet. For services like this there really should be 24/7 coverage but I suspect I won't receive a response until Monday.
     
  13. DebugLogError

    DebugLogError

    Joined:
    Jul 24, 2013
    Posts:
    41
    I have been using 2019.2.10 locally. Forcing Cloud Build to use 2019.2.9 did fix the build failing.

    However, I get a native crash when running the successful builds on Android or iOS (both 2019.2.10 and 2019.2.9). The crash may be unrelated, but rolling back to 2019.2.8 fixes both issues.
     
  14. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    Yeah if you are using 19.2.10 locally then setting "Auto Detect" doesn't help because the problem is with THAT version. You need to get UCB to build with 19.2.9 instead either by rolling back locally or forcing it in the cloud build. I didn't realize you could force a specific version in UCB so I just rolled back locally.

    EDIT: The big "problem" I have with this though is I prefer to have my build targets set to use "Latest 2019.2" which I can't do now and this issue makes me think that might be dangerous to use in general. It would be nice to know that a new build isn't added to UCB until it is validated to be good.
     
    DebugLogError likes this.
  15. jwvanderbeck

    jwvanderbeck

    Joined:
    Dec 4, 2014
    Posts:
    733
    Well the "Auto Detect Version" isn't very reliable either as it was working fine and now my mac target is immediately failing saying it couldn't parse the projectVersion.txt. Strangely it just immediate errored. It didn't even check out the project from Git before declaring it bad!

    The Windows target seems to still be building, or at least it is checking out from Git now rather than just immediate fail. I'll monitor it.

    But this is really troublesome to me. I can't reliably let UCB decide the version to use no matter how I set things up! If I let it use the latest build of a given version, then I risk the problem in this thread where a new version was added to UCB and broke things. If I tell it to read the version from my project and just use that version, then apparently UCB isn't able to reliably do that.

    EDIT: Ok the Windows build target is still going, but I can already see it detected the version fine. So I have no idea why the mac target **which is built from the exact same source** just barfed out immediately while the windows target is fine.
     
unityunity