Search Unity

  1. New Unity Live Help updates. Check them out here!

    Dismiss Notice

Feedback [Bug?] GetDownloadSizeAsync returns 0 for local assets that are not up-to-date with remote

Discussion in 'Addressables' started by TigerHix, Mar 26, 2020.

  1. TigerHix

    TigerHix

    Joined:
    Oct 20, 2015
    Posts:
    23
    Using Addressables 1.7.2.

    The asset I loaded was in an addressable group with following settings:
    • Build path set to LocalBuildPath and load path set to LocalLoadPath.
    • Content Update Restriction - Update Restriction set to "Can Change Post Release" (non static).
    • "Include In Build" is checked.
    The active profile has build path set to RemoteBuildPath and load path set to RemoteLoadPath (on GCP).

    First I built the catalog and addressable groups, built an .apk file and installed it onto my Android device. Then I made some changes to the asset, rebuilt the catalog & addressable groups, uploaded it to remote (GCP), and ran the game on my device. The game first called Addressables.CheckForCatalogUpdates() and Addressables.UpdateCatalogs to fetch the newer catalog from remote. Then, it checked if the asset has a newer version by using Addressables.GetDownloadSizeAsync. This should return the size of the actual updated asset, but 0 was returned. However, when it called Addressables.InstantiateAsync, the latest version of the asset was downloaded and instantiated.

    Note if I perform the same operations but with an asset that is in an addressable group with build path set to RemoteBuildPath and load path set to RemoteLoadPath, then GetDownloadSizeAsync works just fine.

    Is this intended behavior or a bug? Any workaround for this?
     
  2. TreyK-47

    TreyK-47

    Unity Technologies

    Joined:
    Oct 22, 2019
    Posts:
    210
    I'll forward this to the team to have a look. Which version of the editor are you using?
     
    TigerHix likes this.
  3. TigerHix

    TigerHix

    Joined:
    Oct 20, 2015
    Posts:
    23
    2019.2.21f1. Appreciate it!
     
unityunity