Search Unity

  1. Check out our Unite Austin 2017 YouTube playlist to catch up on what you missed. More videos coming soon.
    Dismiss Notice
  2. Unity 2017.2 is now released.
    Dismiss Notice
  3. The Unity Gear Store is here to help you look great at your next meetup, user group or conference. With all new Unity apparel, stickers and more!
    Dismiss Notice
  4. Introducing the Unity Essentials Packs! Find out more.
    Dismiss Notice
  5. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice
  6. Unity 2017.3 beta is now available for download.
    Dismiss Notice

Build warnings like: 'Failed to add the asset file size for' in 5.2.0p1

Discussion in 'Android' started by mark71, Sep 23, 2015.

  1. mark71

    mark71

    Joined:
    Jun 14, 2015
    Posts:
    41
    These warnings are shown in the Console window.

    Failed to add the asset file size for b24777957ec9d44649061dab714daf90
    Failed to add the asset file size for sharedassets0.resource
    Failed to add the asset file size for sharedassets10.resource


    What does this mean and what causes these warnings?
    Unity 5.2.0f3 doesn't show them.
     
    Tactical_Beard, JoRouss and spryx like this.
  2. CDF

    CDF

    Joined:
    Sep 14, 2013
    Posts:
    424
    This is happening to me too. And my Android builds are no longer working...
     
  3. mark71

    mark71

    Joined:
    Jun 14, 2015
    Posts:
    41
    I have reported the bug: 730075
    My builds seem to work fine, at least on the device that I am using to verify the builds.
     
    Last edited: Sep 24, 2015
  4. diego-vieira

    diego-vieira

    Joined:
    Mar 27, 2015
    Posts:
    18
    My builds are working so far, but the message appears to me as well:
    - Failed to add the asset file size for resources.resource
     
  5. TimGS

    TimGS

    Joined:
    Apr 24, 2014
    Posts:
    63
    Same here. App builds fine though and there's no problem during play.
     
  6. henkjan

    henkjan

    Joined:
    Aug 1, 2013
    Posts:
    92
    For me it happens when building for Android. And when I run the app on the android device there is no audio (loaded from resources).
    I'm testing it in Unity 5.2.1f1
     
  7. BIGsmall

    BIGsmall

    Joined:
    Sep 24, 2015
    Posts:
    38
    same here
     

    Attached Files:

  8. neonblue

    neonblue

    Joined:
    Sep 23, 2015
    Posts:
    11
    Same error for two assets on 5.2.1
     
  9. ekt

    ekt

    Joined:
    Jul 9, 2012
    Posts:
    22
    Same here. In my case, the shown guid points to FacebookSettings.cs
    @mark71: whare can I find your bug report? I could not find 730075 in the issue tracker.
     
  10. mark71

    mark71

    Joined:
    Jun 14, 2015
    Posts:
    41
    I don't know why it is not shown in the issue tracker, the bug report number is correct.
     
  11. neonblue

    neonblue

    Joined:
    Sep 23, 2015
    Posts:
    11
    How do you match the GUIDs?
     
  12. spryx

    spryx

    Joined:
    Jul 23, 2013
    Posts:
    273
    Getting all sorts of these errors.... in 5.2.1p1

    Opened a bug report, case: 730952

    Yes, I misspelled add (not ass, Sorry, UT)...lol...leave it to me to turn a simple, 3-letter word into foul language :)

    I think this might be related to resource loading....it seems like everyone in this thread is using assets from a resource folder.
     
    Last edited: Sep 27, 2015
  13. ekt

    ekt

    Joined:
    Jul 9, 2012
    Posts:
    22
    (there must be some kind of moderation over the issue tracker - i cant see 730075 nor 730952)
    @neonblue: i just did a grep. having asset serialization set to text probably helps
     
  14. spryx

    spryx

    Joined:
    Jul 23, 2013
    Posts:
    273
    There is something definitely wrong here.....This happens on Android builds for any of my projects.
    These are the build warnings:
    Failed to add the asset file size for 0000000000000000e000000000000000
    UnityEditor.HostView:OnGUI()
    Failed to add the asset file size for 26fb561ad9edbbb4dab574bfc05a34bc
    UnityEditor.HostView:OnGUI()
    Failed to add the asset file size for 2e1707c781be2c343913342b5363a7ce
    UnityEditor.HostView:OnGUI()
    Failed to add the asset file size for 921ed4b4b9f60dc43b3d03984c444ba1
    UnityEditor.HostView:OnGUI()
    Failed to add the asset file size for a811bde74b26b53498b4f6d872b09b6d
    UnityEditor.HostView:OnGUI()
    Failed to add the asset file size for e24c71bfe7d1b28489e1c7ec73667c53
    UnityEditor.HostView:OnGUI()

    The first warning shows up on every project. Sometimes I get Failed to add the asset file size for sharedassets0.resource.

    My builds are also behaving as though some scripts are missing. Can anyone else confirm strange behavior on builds? My serialized dictionaries seem to be affected in builds only.

    @ekt I believe that bugs have to be reviewed before they are posted to the tracker.
     
    Last edited: Sep 27, 2015
  15. ekt

    ekt

    Joined:
    Jul 9, 2012
    Posts:
    22
    I haven't noticed any strange behaviour, to me it seems to be working as before.
    Happens on Android builds, not on winclient
    building from the command line, there's a stack trace, might be usefull for unity devs
    Code (CSharp):
    1. Failed to add the asset file size for 25d16bd96ce334bc4b521072c4441caa
    2. UnityEditor.BuildPipeline:BuildPlayerInternalNoCheck(String[], String, BuildTarget, BuildOptions, Boolean, UInt32&)
    3. UnityEditor.BuildPipeline:BuildPlayerInternal(String[], String, BuildTarget, BuildOptions, UInt32&) (at C:\buildslave\unity\build\artifacts\generated\common\editor\BuildPipelineBindings.gen.cs:198)
    4. UnityEditor.BuildPipeline:BuildPlayer(String[], String, BuildTarget, BuildOptions) (at C:\buildslave\unity\build\artifacts\generated\common\editor\BuildPipelineBindings.gen.cs:145)
    5. ContinuousIntegration:BuildAndroidApk() (at Assets\Editor\ContinuousIntegration.cs:23)
    6. [C:/buildslave/unity/build/Editor/Src/Utility/FilesizeInfo.cpp line 89]
    7. (Filename: Assets/Editor/ContinuousIntegration.cs Line: 23)
    8.  
     
  16. henkjan

    henkjan

    Joined:
    Aug 1, 2013
    Posts:
    92
    In my case it's already set to text. Didn't help. Also I've tried several different sound settings (in my case I don't hear sounds living in resources on android). Didn't help either.
     
  17. neonblue

    neonblue

    Joined:
    Sep 23, 2015
    Posts:
    11
    Ok, this explains why I'm seeing issues on my display after deployment... Some resources that are key for layout are not getting included. This is a huge deal....
     
  18. ZyntharNOR

    ZyntharNOR

    Joined:
    Sep 20, 2013
    Posts:
    12
    I'm seeing the same type of errors, the build seems to work fine though.
     
  19. spryx

    spryx

    Joined:
    Jul 23, 2013
    Posts:
    273
    Yes, I have resources missing from builds as well :(
    @ekt How were you able to build from the command line? I would like to take a look at the stack traces
     
  20. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
    Hello all,

    The warning messages you're seeing is part of a change we introduced in the latest patch in order to include the contents of the Resources folder in the output stats logfile, which is a feature that has been requested by some of our customers. I'll analyze the case reports you have submitted and find out why are the warning messages being printed in the first place, because that shouldn't really be the case under normal circumstances.

    Notice that this new feature doesn't have any impact whatsoever in the build process itself; it only affects the output stats calculation. So if you're having issues when building your projects, the problem might be something else.

    Edit: typo.
     
    Last edited: Sep 28, 2015
  21. summerian

    summerian

    Joined:
    Jul 6, 2014
    Posts:
    60
    I'm having the same problem and there are things missing in my android build which were working right up to the upgrade. As far as I can see it has only affected 9 slice backgrounds in UI panels, but I'm getting far more warnings than I can visually identify.
     
  22. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
    Hello summerian,

    If you can submit a bug report with a minimal repro case (or as minimal as you can make it!), let me know the case number and I'll look into it.
     
  23. summerian

    summerian

    Joined:
    Jul 6, 2014
    Posts:
    60
    Sure, I'll try first thing in the morning.
     
  24. ekt

    ekt

    Joined:
    Jul 9, 2012
    Posts:
    22
    @spryx: command line build is basically executing unity.exe with some parameter. something like
    Code (CSharp):
    1. unity.exe -quit -batchmode -buildTarget android -executeMethod ContinuousIntegration.BuildAndroidApk -projectPath %projectFolder%  -logFile %LocalLogFile% -outputFile %outBinaryAndroid%
    ContinuousIntegration.BuildAndroidApk is a script you write, where you eventually call BuildPipeline.BuildPlayer(). I can share you mine, but there are lots of resources out there explaining it much better.

    Attached, the build logs. Stack trace is around line 440.
     

    Attached Files:

    Last edited: Sep 28, 2015
    spryx likes this.
  25. Simon-O

    Simon-O

    Joined:
    Jan 22, 2014
    Posts:
    18
    I'm getting 700+ of these errors on a Windows build and while the build appears to succeed, some things which work in the editor do nothing in the player. Feels like scripts are missing/not being wired up.
     
    JoRouss likes this.
  26. spryx

    spryx

    Joined:
    Jul 23, 2013
    Posts:
    273
    @ekt thank you for the tip and the script

    I suppose the problems I am having have something to do with my serialized dictionary :/... sigh.
     
  27. henkjan

    henkjan

    Joined:
    Aug 1, 2013
    Posts:
    92
    Thanks for clearing this out. I'll just ignore these messages.
    Remains the fact that my audio resources are not loading/playing when building for Android. They work in the editor and because this is originally a Unity 4.6 project, it's strange it's not working when upgrading to 5.2.1f1
     
  28. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
    Hello henkjan,

    A couple of questions about this: did you upgrade your 4.6 project straight into 5.2.1p1? Or did you use 5.21f1 as an intermediate step?

    Cheers,
     
  29. neonblue

    neonblue

    Joined:
    Sep 23, 2015
    Posts:
    11
    I was on 5.2.0 before and didn't have the warning with the same project. But after upgrading to 5.2.1f it did.
     
  30. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
    Hello neonblue,,

    Please submit a bug report with a repro case, let me know the case number and I'll look into it.

    Best,
     
  31. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
    Hello spryx,

    I tested the repro project attached to this case, but I didn't get any warning messages when creating the build. The target platform is set to "WebPlayer", is that correct?

    Best,
     
  32. spryx

    spryx

    Joined:
    Jul 23, 2013
    Posts:
    273
    @Ignacio Liverotti
    No, the platform should be Android... Thanks for testing
     
  33. henkjan

    henkjan

    Joined:
    Aug 1, 2013
    Posts:
    92
    I first went to 5.2.1f1. Then to 5.2.1p1 and then back to 5.2.1f1
    (target platform Android)
     
  34. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
    @spryx: Gotcha, thanks for the info. I've tested it here and I can reproduce the warning messages. I'm currently developing a fix, will keep you posted.

    @henkjan : The warning messages shouldn't have any impact on your audio resources. If you have a moment, please create a repro case, submit a bug report, let me know the case number and I'll look into it.
     
  35. henkjan

    henkjan

    Joined:
    Aug 1, 2013
    Posts:
    92
    I will thanks (I'm a bit busy so I hope tomorrow)
     
  36. henkjan

    henkjan

    Joined:
    Aug 1, 2013
    Posts:
    92
    @Ignacio Liverotti : I've created a project to demonstrate the problem en submitted the problem. You can find it in Unity's FogBugz under ticket number: 732568
    Hopefully it wil help :)

    UPDATE: I found out what my problem was! Because of performance reasons I had a method that loaded the resource file and unloaded the asset. I had read somewhere that it's the best way to do it:

    private AudioClip GetAudioClip(string path)
    {
    var result = Resources.Load < AudioClip>(path);

    Resources.UnloadAsset(result);
    return result;
    }


    Although this works in the editor and on the web, Android and iOS with Unity 4, it doesn't work anymore in Unity 5.2.1f1 targetting Android. So removing the UnloadAsset line fixes the problem.
     
    Last edited: Oct 2, 2015
  37. Ironcross

    Ironcross

    Joined:
    Jun 24, 2014
    Posts:
    14
    Same issue after upgrading for Unity 5.2.1 got this error when building fro Android, also some of images of scenes where crashed. Static Scenes like Menu and Shop Dramatically draped in FPS... everything looks extremely laggy... some animation on UI elements not working at all. But in game scene everything looks all right. (2d platformer game).
    upload_2015-10-1_13-31-30.png


    Screenshot_2015-10-01-13-27-12.png
     
    Last edited: Oct 1, 2015
  38. Thiemo

    Thiemo

    Joined:
    Jan 15, 2013
    Posts:
    5
    Same here. I get "Failed to add the asset file size for ..." on every android build. I am on 5.2.1
     
    Last edited: Oct 2, 2015
  39. screenname_taken

    screenname_taken

    Joined:
    Apr 8, 2013
    Posts:
    547
    Ironcross likes this.
  40. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
    Excellent henkjan, very happy to hear that!

    To anyone else experiencing the issue with the warning messages: I've submitted a fix for this, which is currently under review by the R&D Team. The warning messages shouldn't affect the generated builds at all.
     
    Tactical_Beard and Ironcross like this.
  41. Ironcross

    Ironcross

    Joined:
    Jun 24, 2014
    Posts:
    14
    Thanks mate! But it looks much better with animation and without mosaic)
     
  42. Ironcross

    Ironcross

    Joined:
    Jun 24, 2014
    Posts:
    14
    Great News, Thank you! I Hope it will work and they will fix this ridicules error in an upcoming patch.
     
  43. Velo222

    Velo222

    Joined:
    Apr 29, 2012
    Posts:
    1,143
    Just wanted to add I'm getting these errors as well and I'm developing for Windows desktop standalone. I'm getting 96 of them in one of my projects after building. It doesn't keep me from building and playing the game, but I am noticing some weird frames where some of my assets will disappear for a frame or two. But it could be a 3rd party plugins fault and not Unity's.

    Anyways, one of the errors looks like this:

    "Failed to add the asset file size for GI/mainData/0c/0c16a81e85ff6f54421aa53fad40d977.ecm
    UnityEditor.HostView:OnGUI()"

    I upgraded from version 5.1.1p1 to 5.2.1p2.
     
  44. Ironcross

    Ironcross

    Joined:
    Jun 24, 2014
    Posts:
    14
    Any news?
     
  45. MathBlade

    MathBlade

    Joined:
    Aug 18, 2015
    Posts:
    9
    Some of my art assets that are as simple as an empty game objects are losing their color on a build. I've tried recreating and reimporting numerous times. It lasts a short while then repeats. Going to version 5.1 is not an option as I tried but then Unity can't find the Dropdown class needed (mind you the prefab works fine ...somehow?) in my scripts and forceActive true is missing.

    Do you know about when (approximately) this would be released?
     
  46. MathBlade

    MathBlade

    Joined:
    Aug 18, 2015
    Posts:
    9
    empty game objects with an image component in them*
     
  47. Ignacio-Liverotti

    Ignacio-Liverotti

    Unity Technologies

    Joined:
    Jul 23, 2015
    Posts:
    36
  48. CDF

    CDF

    Joined:
    Sep 14, 2013
    Posts:
    424
    We had to role back to 5.1.1, Just too many issues with 5.2 including this one
     
  49. mark71

    mark71

    Joined:
    Jun 14, 2015
    Posts:
    41
    Besides the warnings I get this error quite often (50%) when making a build:
    "Cannot load Atlas During Build/Enter Game. Missing File ?"
    Can it be ignored like the warnings?
    Unity 5.2.1p2
     
  50. Zullar

    Zullar

    Joined:
    May 21, 2013
    Posts:
    462
    I have the same error. It's failing to load my audio clips when I build (although things work fine in the editor).