Search Unity

Error during addressables build

Discussion in 'Localization Tools' started by A_Savvidis, Dec 18, 2020.

  1. A_Savvidis

    A_Savvidis

    Joined:
    Jul 21, 2016
    Posts:
    98
    So following the instructions on the Localisation guide I was at the "Window/Asset Management/Addressable Assets/Groups by clicking Build/New Build/Default Build Script" part and I got this error:

    ArgumentException: Asset 'Library/unity default resources' is not a valid Asset or Scene.
    UnityEditor.Build.Pipeline.BundleBuildContent..ctor (System.Collections.Generic.IEnumerable`1[T] bundleBuilds) (at Library/PackageCache/com.unity.scriptablebuildpipeline@1.15.1/Editor/Shared/BuildContent.cs:147)
    UnityEditor.AddressableAssets.Build.DataBuilders.BuildScriptPackedMode.DoBuild[TResult] (UnityEditor.AddressableAssets.Build.AddressablesDataBuilderInput builderInput, UnityEditor.AddressableAssets.Build.DataBuilders.AddressableAssetsBuildContext aaContext) (at Library/PackageCache/com.unity.addressables@1.16.15/Editor/Build/DataBuilders/BuildScriptPackedMode.cs:177)
    UnityEditor.AddressableAssets.Build.DataBuilders.BuildScriptPackedMode.BuildDataImplementation[TResult] (UnityEditor.AddressableAssets.Build.AddressablesDataBuilderInput builderInput) (at Library/PackageCache/com.unity.addressables@1.16.15/Editor/Build/DataBuilders/BuildScriptPackedMode.cs:77)
    UnityEditor.AddressableAssets.Build.DataBuilders.BuildScriptBase.BuildData[TResult] (UnityEditor.AddressableAssets.Build.AddressablesDataBuilderInput builderInput) (at Library/PackageCache/com.unity.addressables@1.16.15/Editor/Build/DataBuilders/BuildScriptBase.cs:84)
    UnityEditor.AddressableAssets.Settings.AddressableAssetSettings.BuildPlayerContentImpl () (at Library/PackageCache/com.unity.addressables@1.16.15/Editor/Settings/AddressableAssetSettings.cs:1909)
    UnityEditor.AddressableAssets.Settings.AddressableAssetSettings.BuildPlayerContent () (at Library/PackageCache/com.unity.addressables@1.16.15/Editor/Settings/AddressableAssetSettings.cs:1891)
    UnityEditor.AddressableAssets.GUI.AddressableAssetsSettingsGroupEditor.OnBuildPlayerData () (at Library/PackageCache/com.unity.addressables@1.16.15/Editor/GUI/AddressableAssetsSettingsGroupEditor.cs:280)
    UnityEditor.AddressableAssets.GUI.AddressableAssetsSettingsGroupEditor.OnBuildScript (System.Object context) (at Library/PackageCache/com.unity.addressables@1.16.15/Editor/GUI/AddressableAssetsSettingsGroupEditor.cs:275)
    UnityEditor.GenericMenu.CatchMenu (System.Object userData, System.String[] options, System.Int32 selected) (at <7d90b28560b644ce87b8263efcc36eed>:0)

    Any thoughts?
     
  2. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,297
    Can you try updating to the latest version of Addressables? You can do this through the package manager.
     
  3. A_Savvidis

    A_Savvidis

    Joined:
    Jul 21, 2016
    Posts:
    98
    Hi there again Karl Nice to see you again (I was at the webinar yesterday).
    That was the fist thing I did but to tell you the truth I had never used addressables before. Digging into them today, maybe I missed something that was super-obvious? I really don't know. As you can see above in the error report I'm using Addressables 1.16.15 Unity 2019.4.16
     
  4. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,297
    Oh nice to see you again! I hope you found it useful. :D
    What assets have you localized? Did you use some assets from unity default resources? E,g the default sprites etc? I suspect this may be a bug when using builtin assets with addressables.
    As these assets are already included in Unity we dont need to build them into Addressables, we just need to load them from the builtin resources. Ill speak to the Addressables team to see if they have any ideas.
    For now the simplest thing to do would be to copy the builtin resources you want to use, so they are a normal asset in the project.
     
    Last edited: Dec 18, 2020
  5. A_Savvidis

    A_Savvidis

    Joined:
    Jul 21, 2016
    Posts:
    98
    @karl_jones that must have been it!

    I wanted to do a quick test so I indeed used the primatives but it failed even after I deleted that table. Apparently I also had to clean the build.on the addressables windows. It works fine now. Thank you.
     
    karl_jones likes this.