Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

Unity 5.4.0b10 - Build Failure on First Attempt, Pass on Second

Discussion in '5.4 Beta' started by CyberGrim, Apr 14, 2016.

  1. CyberGrim

    CyberGrim

    Joined:
    Apr 14, 2016
    Posts:
    2
    Hey all,

    Ever since we upgraded our build machines to Unity 5.4.0b10, we've been getting a strange error where the build will always fail the first time (without anything massively useful in the logs, just "Error building Player: 11 errors", which I can never find reference to) and then it will pass the second time without issue.

    I've come to the conclusion that it has to be something to do with the importing of assets since if anyone just checks in a code change, it will pass, but if there's a change to an asset (be it a .prefab or even a simple .png) it will fail the first time and then pass the second time.

    Nothing changes in the code base - unless I allow it - so the reason that it passes the second time has to be something that's happening during the first phase which fails. I worked around this, from a Continuous Integration perspective, by creating a "Fail Job", with the "Success Job" immediately following it, but any help towards a more permanent solution would be greatly appreciated.
     
  2. Peter77

    Peter77

    QA Jesus

    Joined:
    Jun 12, 2013
    Posts:
    6,619
    Any chance you use the Asset Cache Server? We have similar issues, textures that break the build on 1st attempt and work fine on 2nd without having anything changed in-between. We believe that it's caused by cache server weirdness, because wiping the asset cache makes this issue disappear for a couple of days to weeks with our project.
     
  3. CyberGrim

    CyberGrim

    Joined:
    Apr 14, 2016
    Posts:
    2
    We used to use the cache server, but aren't any more (I'll double check, but I don't think so), and my test bed that I use to test out different build processes definitely doesn't use one; but exhibits the same behaviour.

    I'll have a poke around in this area though, see if I can at least get some more information from it.

    Thanks for the heads up.
     
  4. superpig

    superpig

    Drink more water! Unity Technologies

    Joined:
    Jan 16, 2011
    Posts:
    4,659
    The 11 errors _should_ be earlier in the log, somewhere - shaders that failed to compile for the target platform is a common cause. Note that in a future beta, these errors will not cause the build to fail unless you turn on the behaviour with a flag to the build pipeline API.