com.unity.addressables icon indicating copy to clipboard operation
com.unity.addressables copied to clipboard

Duplicate address 'AddressablesMainContentCatalogRemoteHash'

Open V0odo0 opened this issue 1 year ago • 6 comments

After proper setup and building with Multi-Catalog the console gives the following error on each asset load attempt from remote group in runtime: Duplicate address 'AddressablesMainContentCatalogRemoteHash' with id 'https://here_is_my_domain//catalog_1.hash' found, skipping...

I haven't found anything related to this error on web. Any clues?

V0odo0 avatar Jun 29 '23 00:06 V0odo0

Remote groups, or remote loading is (currently) not supported. This package assumes all content is stationed locally for loading.

Reason for this being absent is that I have yet to use it myself (so I have no clue what's going on under the hood), and It's quite involved in terms of keeping track of updates in the internal state object.

If you have a simple reproduction case, I can have a look at it to fix this issue specifically. But otherwise, I think your best bet it to fork this repo and add it yourself for working with remote content.

juniordiscart avatar Jun 29 '23 05:06 juniordiscart

If you have a simple reproduction case, I can have a look at it to fix this issue specifically. But otherwise, I think your best bet it to fork this repo and add it yourself for working with remote content.

To reproduce: The main catalog should be loaded from remote server. Check for catalog updates on startup.

Three groups:

  1. Local (built-in). Placed under streaming assets folder
  2. Local (with multi-catalog setup). Placed under mods folder. Might have objects with references to Local (built-in)
  3. Remote. Some of the objects has references to Local (with multi-catalog setup).

I've got this error without even trying to load Local (with multi-catalog setup) catalog.

V0odo0 avatar Jun 29 '23 10:06 V0odo0

Yeah, I encountered this issue too. The option to build a remote catalog is probably ignored so a local catalog is always loaded. That is why an attempt to load a remote one creates a conflict. Disabling 'Build Remote Catalog' eliminates this error but one can't load a remote catalog without an app rebuild.

dnnkeeper avatar Oct 25 '23 16:10 dnnkeeper

Are there any ideas to solve this problem? I want to try it, but I am not familiar with this library.

tangxianbo avatar Feb 12 '24 13:02 tangxianbo

@tangxianbo I guess the only way to mitigate this error is to avoid dependencies from Remote to External groups.

I managed to make a remote catalog setup like this:

  • Essential assets in the Remote Group (set as default).
  • Additional assets in External Groups (set as local and added to external catalog setup)
  • Duplicate asset isolation groups are marked as remote and not included in any external setup

So until external groups have no assets that remote group depends on you should be fine

dnnkeeper avatar Feb 12 '24 15:02 dnnkeeper

@dnnkeeper Thanks for your reply, I understand. I will take some time to get familiar with this library and see if it can be more flexible

tangxianbo avatar Feb 13 '24 00:02 tangxianbo