Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Remote download path always set to RemoteBuildPath

Discussion in 'Addressables' started by novaVision, Mar 21, 2021.

  1. novaVision

    novaVision

    Joined:
    Nov 9, 2014
    Posts:
    491
    Some very weird things just happened in my project. I worked on Unity Cloud Content Delivery system integration and I had to set the RemoteLoadPath from my script - it had to be generated according to current platform and set the proper bucket id. After playing with this Addressables remote loading stopped working at all - it always refer to RemoteBuildPath (ServerData/[BuildTarget]) instead of RemoveLoadPath.

    I tried to cleanup all cache, rebuild - nothing helped. I tried to restore to direct asset load URL which worked fine before but it also still refer to RemoteBuildPath.

    I even tried to remove => install the Addressables package, and still nothing.

    What kind of magic is it?
    sample.png

    Code (CSharp):
    1.  
    2. Exception encountered in operation Resource<IAssetBundleResource>(lesson_1.bundle), status=Failed, result= : Invalid path in AssetBundleProvider: 'ServerData/Android/remote_scenes_lessons/lesson_1.bundle'.
    3.  
    4. UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationBase`1/<>c__DisplayClass55_0<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>:<add_CompletedTypeless>b__0 (UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>)
    5. DelegateList`1<UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>>:Invoke (UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>) (at /Users/Romaha/Documents/Projects/2021/CatoScience/Library/PackageCache/com.unity.addressables@1.16.16/Runtime/ResourceManager/Util/DelegateList.cs:69)
    6. UnityEngine.AddressableAssets.Initialization.InitializationOperation/<>c__DisplayClass16_0:<LoadContentCatalogInternal>b__0 (UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>)
    7. DelegateList`1<UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>>:Invoke (UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>) (at /Users/Romaha/Documents/Projects/2021/CatoScience/Library/PackageCache/com.unity.addressables@1.16.16/Runtime/ResourceManager/Util/DelegateList.cs:69)
    8. UnityEngine.ResourceManagement.ChainOperation`2<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator, UnityEngine.AddressableAssets.ResourceLocators.ContentCatalogData>:OnWrappedCompleted (UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>)
    9. DelegateList`1<UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>>:Invoke (UnityEngine.ResourceManagement.AsyncOperations.AsyncOperationHandle`1<UnityEngine.AddressableAssets.ResourceLocators.IResourceLocator>) (at /Users/Romaha/Documents/Projects/2021/CatoScience/Library/PackageCache/com.unity.addressables@1.16.16/Runtime/ResourceManager/Util/DelegateList.cs:69)
    10. UnityEngine.ResourceManagement.ResourceManager:Update (single)
    11. MonoBehaviourCallbackHooks:Update () (at /Users/Romaha/Documents/Projects/2021/CatoScience/Library/PackageCache/com.unity.addressables@1.16.16/Runtime/ResourceManager/Util/MonoBehaviourCallbackHooks.cs:26)

    I am on Unity 2020.2.7, Mac, Target Platform - Android
     
    Kamand0l likes this.
  2. novaVision

    novaVision

    Joined:
    Nov 9, 2014
    Posts:
    491
    After tons of testing I found that this happens only with "Bundle Naming" set to "Filename". Settings it to "Append Hash to Filename" fixed the issue. Is it a bug or expected behaviour? If expected, can someone explain me please, why?
     
  3. Kamand0l

    Kamand0l

    Joined:
    May 19, 2014
    Posts:
    24
    Please, I would like to know this too as using "Filename" for "Bundle Naming" is critical to aid in getting deterministic asset bundles.
     
  4. TreyK-47

    TreyK-47

    Unity Technologies

    Joined:
    Oct 22, 2019
    Posts:
    1,796
    I'll raise this with the team for their input!
     
  5. davidla_unity

    davidla_unity

    Unity Technologies

    Joined:
    Nov 17, 2016
    Posts:
    736
    Hey all, what versions of the package are you using? There was an issue with Filename bundle naming that we fixed semi-recently. The latest version of the package is 1.17.15 so give updating a try and see if you're hitting the issue we already fixed. You may need to clean your build cache before rebuilding.

    If you're still seeing the problem please file a bug with a project that reproduces the issue.
     
  6. novaVision

    novaVision

    Joined:
    Nov 9, 2014
    Posts:
    491
    David, if you would check my log I provided initially you would see this:
    Code (CSharp):
    1. com.unity.addressables@1.16.16
    I believe that's the answer for your question.

    Will check new 1.17.15