Hi all,
I don’t know what happened but suddenly my compile time increased to 40 min from 5 min. It tries to compile hidden URP shaders and I don’t have any idea why…
I’ve experienced this, except sometimes the compile time stretches into the hours. I’m sure there’s some bug at the bottom of this that I never got to discover, but there’s plenty of threads about that provide band-aid solutions, like this one: Compiling Shader Variants Taking Ages
Lots of possible solutions in there, some worked, some didn’t. Removing Vulkan from the compile options got my shader compilation time down to about 20 minutes. Not great but… better than hours.
Interestingly it is gone as it is seen after restarting Unity
Once you compile it caches the shaders, so until your shaders change or your cache is cleared, you won’t have to build the shader varients again.
I have the same problem, except in my case it goes over 27 hours and never completes. Did you update to Unity 2020.3.17?
Which Unity version are you on?
Do you have particle systems in the project?
I really don’t like to recommend it but as it is well known deleting library folder and let the unity import all of your project from the beginning (hours…) can be the solution.
if that is not the solution sometimes I found refactoring is the best solution. (make a clean project, install your packages again and transfer your individual files into it)
Hi, I tried on 2020.3.16 and 2020.3.17 and URP. Yes I do have and use both VFX graph and the old particle system. 5 days and counting. Nothing I tried have worked so far. I have left it going up to 27+ hours seem to to get stuck (even though I see it is counting up) at 50% or it it keeps looping hard to tell.
Thanks, yeah I have already several times and didn’t help. Deleting the library has been a routine thing for me, do it at least every 3 days to make the editor perform better, I am lucky that this happens under an hour on my pc despite my project being 60gb (most of which is ironically is the library).
I am going to create a clean project today and try again. After that I am out of options.
I was able to solve my issue, at least for now.
See here: URP 120k+ Shader Varients - Unity Engine - Unity Discussions