Push/Pop Asset Dependencies with AssetBundle.CreateFromMemory

Hi there. I’m unsure of whats causing this issue but here is what comes up in the webplayer log:

Asset bundle is incomplete
 
(Filename: C:/BuildAgent/work/d9c061b1c154f5ae/Runtime/Misc/AssetBundleUtility.cpp Line: 240)

This happens only in webplayer.

When i build the bundle(s) i use BuildPipeline.PushAssetDependancies and BuildPipeline.PopAssetDependancies and inside those calls i build the bundle(s) with the deterministic option so that i can have bundles that don’t need to be redownloaded when any part of the project changes.

When i load/create the bundles i get a byte[ ] off of a WWW and use AssetBundle.CreateFromMemory.

In Editor this is fine, all works. But in Webplayer i get the above message in log that happens some time between the call to CreateFromMemory or .assetBundle off the AssetBundleCreateRequest. .assetBundle returns null.

Additional info:
-I am mixing streamed-scene bundles in the pipeline as well.
-I am loading the bundles in the same order of dependancies i build them with.
-I am buidling multiple bundles between pushes, so that those between pushes do not directly depend on eachother ( it seems like this is supported going by file size of the built bundles )

Thoughts:
I went through all documentation i could find and searched for that error in google. You get absolutely nothing when you search “Asset bundle is incomplete” (with quotes).

The one peice of documentation that i’ve found that bothers me is here: Unity - Scripting API: BuildPipeline.PushAssetDependencies

Specifically this:

If its true (please let me know if it is) that i can’t encode my bundles at all ( which i am not currently, so its not related to this issue ) and i have to use WWW.assetBundle to load rather than going through the bytes manually; beyond better clarification of this in documentation unity really needs to do away with this requirement .

I can confirm now that if you use WWW.assetBundle vs. AssetBundle.CreateFromMemory the error no longer happens. So that little sentence in documentation about PushAssetDependancies and PopAssetDependancies is correct.

So to sum up the problem ( since i’m positive the next time someone googles “Asset bundle is incomplete” this will be the only result of value )

Unity says: ( from my mouth )
You cannot use push asset BuildPipeline.PushAssetDependancies before building any bundle that you plan on encrypting / decrypting with use of AssetBundle.CreateFromMemory in web player.

You are forced to use WWW.assetBundle and have no means of encrypting bundles when using the features to reduce redundancy included with your unity pro license.

I’d love to be proved wrong here, and even more than some sort of documention mentioning this flaw with unity in documentation for AssetBundle.CreateFromMemory (which if there is any its very hard to find) I’d prefer unity fixing this before they drop support for 3.5 entirely at the end of the year. Having multiple pages about how to encrypt stuff manually throughout the manuals to me are pointless and broken unless you want to waste duplicates without using push/pop.

Just as a followup, When outside of webplayer and AssetBundle.CreateFromFile is used there seems to be no issues as well. So thats another undocumented thing as in you do not need to use WWW always to load dependant asset bundles ( since afaik you cant use createfromfile in webplayer, you do always have to use WWW with it ). Either way though this doesn’t solve the giant lacking hole for encryption with dependant bundles in webplayer.