Search Unity

Build Failure - Failed to resolve assembly: UnityEngine.UI

Discussion in 'Unity Build Automation' started by Trivium_Dev, Mar 19, 2018.

  1. Trivium_Dev

    Trivium_Dev

    Joined:
    Aug 1, 2017
    Posts:
    78
    I've started running into an issue with one of my Unity Cloud projects where the build fails. However, I'm able to "fix" it by turning off the Library cache option in the config settings for the Unity Cloud project. Turning library caching back on breaks it again though.

    The error seems to occur around line 1897 in the failed builds, which reads "1897: [Unity] Field 'System.Collections.Generic.List`1<UnityEngine.UI.RawImage> BitDropper::bit1' from 'Library/ScriptAssemblies/Assembly-CSharp.dll', exception Failed to resolve assembly: 'UnityEngine.UI, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'". After that, there are tons of these types of errors, all reporting that it cannot resolve assembly UnityEngine.UI, which makes no sense really.

    I'm able to pull the repo to a fresh location and build it locally.

    It's a small project so turning off library caching doesn't seem to really slow down the builds that much - previous successful builds took between 8 and 16 mins, the one build I did with Library caching off took 9 minutes. Just wondering what's going on and if there's something I can do to fix it.

    Thanks!