[UnityCache] Error when initializing cache: Error: Could not connect to cache: Cache API is not supported.
[UnityCache] Failed to load ‘http://IP_ADDRESS/Build/public.data’ from indexedDB cache due to the error: Error: Could not connect to cache: Cache API is not supported.
I’m using Unity 2022.1.0f1, and I’m trying to host the webGL build by express server.
When I activate server code on my local computer, and access to localhost, it works just fine. It never make that error.
But when I do same thing on my ec2 server, that error comes out. I didn’t care about it so far because webGL worked eventually, but the bigger my project becomes, the loading speed is getting too slow.
When I turn off the data caching from player settings, that error doesn’t come out, but the loading speed is still a problem.
My ec2’s os is ubuntu 22.04, and using t2.micro. Maybe my ec2 is too weak to serve WebGL?
Tell me if there are things to know more.
Question - Unity game WebGL hosting issue [UnityCache] Error when initializing cache - Unity Forum
I think that question is nearly same with my case.
1 Like
Same problem here.
Appeared when i upgraded my project from Unity 2021.3.20 to 2022.1.19.
Project is deployed on a Windows IIS and since we upgraded Unity, addressables cache is not working anymore and we get this error in the browser console log :
[UnityCache] Error when initializing cache: Error: Could not connect to cache: Cache API is not supported.
[UnityCache] Failed to load ‘xxxxx.data.gz’ from indexedDB cache due to the error: Error: Could not connect to cache: Cache API is not supported.
1 Like
That sounds like a non-LTS bleeding edge build of Unity.
Anytime you go beyond LTS you are an unpaid test pilot.
https://discussions.unity.com/t/909358/4
Ideally revert your project to before this attempted update.
If you absolutely cannot revert, try all the usual things:
-
reimport all
-
remove all packages, re-add the latest ones
-
google more for the above error, try some of the many things others have tried
Change from Question to Bug
I am using 2022.3 LTS releas still got the same error when downloading asset bundle.
unity Could not connect to cache: Cache API is not supported.
Anyone please share the solution or it will remain the same?