Search Unity

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:
    69
    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:
    1,822
    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:
    69
    2019.2.21f1. Appreciate it!
     
  4. TreyK-47

    TreyK-47

    Unity Technologies

    Joined:
    Oct 22, 2019
    Posts:
    1,822
    After connecting with the team, it was recommending you file a bug report so that they can investigate this further.

    If you're unsure how to do so, you can find the steps detailed here: https://unity3d.com/unity/qa/bug-reporting