Game crashes when changing scenes on export version

I’m using windows 10.
It works in debug version.
Deleting shader_cache folder or deleting anything inside and then booting up the game solves this problem, but only temporarily. (Until a certain amount of time is passed or game is rebooted)
It only happens when changing scenes, if a scene crashing the game, starting the game in said scene has it work fine.
Using console and reviewing logs, it doesn’t produce a error. Even while using --verbose.

A video of what’s happening

Another video to demonstrate this problem further.

The game scene I was trying to load into works perfectly, but when trying to go back to the main menu, it crashes.

Another video to demonstrate this problem further.

question is how do you change your scene? is this custom made script code to change or it’s built-in SceneTree’s change_to_scene ?
it looks to me you have custom change scene, but only you know what you wrote

if you dont remove_child before queue-ing free the scene, it might result into what you have