Engine recompile a lot of shaders if i delete variable in blueprint

In common situation looks like this.

I add new variable in my blueprint, then I delete it. Or add some logic with variable, then delete this logic, then delete variable.
On delete Unreal starts to load references, resave scenes, recompile huge amount of shaders, etc. and i should wait for a long time it is doing all this stuff.
It looks like storm in a teacup for me.
Whats the reason for all this activity? I just deleted unused variable.

This thing occures for about 1 or 2 last years.

I really appreciate any help to avoid this situation.

Hey there @KariyOhe! Welcome back to the community! When working with blueprints that aren’t doing anything with materials, shader rebuilt shouldn’t be triggered at all.

Does this only occur on one project or all of them?

May I know your specs and engine version?

Hello @SupportiveEntity .

Thank you for reply and sorry for long delay with my answer.
I’ve made few tests on empty project and my working project.
My current suggestion is that the problem is because of a lot of dependences between blueprint classes. So one small BP can have sizemap like 2-3 Gb, because chain of references looks at lot of assets - meshes, materials and textures used in blueprints (and some of them creates material instance and cast parameters into it).
And this huge tangle makes a lot of trouble.
We are working on cleaning dependences, now it’s about 1-1.5Gb, and i’m going to reduce it few times more and then make test with deleting variables again.

Engine version is 4.27.2
Win10 64, i7-6700K, 32Gb, GeForce RTX 2060 Super

Ahh yeah, adjusting the material instances could do it. If you can decouple the BP you’re working with from the material instances, you should be good to go. Once you get the dependencies sorted, let me know how it goes!