I get the following error when trying to get the addressable data and instantiate an object.
2020-12-18 01:00:44.709 29957 9621 Error Unity Exception encountered in operation Resource<IAssetBundleResource>(prefab_assets_all_51075e0f226e599c58238aba4ab95821.bundle): RemoteAssetBundleProvider unable to load from url https://github.com/Name-company/Addressable/Android/prefab_assets_all_51075e0f226e599c58238aba4ab95821.bundle, result='HTTP/1.1 404 Not Found'.
2020-12-18 01:00:44.709 29957 9621 Error Unity (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
2020-12-18 01:00:44.709 29957 9621 Error Unity
2020-12-18 01:00:44.724 29957 9621 Error Unity Exception encountered in operation Dependencies: RemoteAssetBundleProvider unable to load from url https://github.com/Name-company/Addressable/Android/prefab_assets_all_51075e0f226e599c58238aba4ab95821.bundle, result='HTTP/1.1 404 Not Found'.
2020-12-18 01:00:44.724 29957 9621 Error Unity (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
2020-12-18 01:00:44.725 29957 9621 Error Unity Exception encountered in operation Resource<GameObject>(Cube.prefab): Dependency Exception
2020-12-18 01:00:44.725 29957 9621 Error Unity (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
2020-12-18 01:00:44.725 29957 9621 Error Unity Exception encountered in operation Dependencies: Dependency Exception
2020-12-18 01:00:44.725 29957 9621 Error Unity (Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)
But when I check the Json file on the server data folder outside assets,which I upload later into github webpage I can see the bundle there.I don’t know why the error showing - HTTP/1.1 404 Not Found. as the data is still there in the Json file(Parts of the json file given beow).
55 "https://github.com/Name-Company/Addressable/Android/prefab_assets_all_51075e0f226e599c58238aba4ab95821.bundle"
56 "Assets/Prefabs/Cube.prefab"
57 "{UnityEngine.AddressableAssets.Addressables.RuntimePath}/Android/defaultlocalgroup_unitybuiltinshaders_789bb0c4b5bc1f62c7c6fec9891efb0f.bundle"
.
.
.
.
112 "prefab_assets_all_51075e0f226e599c58238aba4ab95821.bundle"
113 "Assets/Prefabs/Cube.prefab"
114 "5d391ea64ae74c3479a03bc143932670"
115 "Models"
116 "defaultlocalgroup_unitybuiltinshaders_789bb0c4b5bc1f62c7c6fec9891efb0f.bundle"
From one scene I login and reach another scene. So in that scene there is an empty GameObject where I attach the below script.At start I am trying to do the AsyncOperation.
I believe in the Start method itself the exception is encountered.
void Start()
{
// 'Label name given------ 'Models'
Addressables.LoadAssetsAsync<GameObject>("Models", OnLoadDone);
}
//Initially just trying to print names of the GameObjects
private void OnLoadDone(GameObject obj)
{
LoadedAssets.Add(obj);
Debug.Log("Count " + loadedAssets.Count);
for (int i = 0; i < loadedAssets.Count; i++)
{
Debug.Log("Load Assets name " + loadedAssets[i].name);
//Instantiate(loadedAssets[i]);
}
}