I'm currently working on a project where we use scritpable objects to store all configs on the game. The problem comes using git since sometimes we lose references stored on those SO.
For example I have a Config called A with a GameObject variable. On my branch "Branch1" the variable is null and on my branch "Branch2" is assigned to a prefab. I'm working on Branch1 and I move to Branch2 but the SO is not updated and the variable is still null although on Branch2 that variable actually had a value.
We have tried to reimport the asset but does not solve anything. The only thing that seems to work is a weird process. If we make a change to the SO after moving to BranchB, we save and then discard changes from git (we use sourcetree) the SO config now is fine as it should be on the current branch.
It's a weird behaviour and more weird solution we have that is leading to a lot of time lost and several errors.
Anyone has an idea of what is happening and knows how to solve it??
We are using Unity2019.1.14f1 and we use Odin for a custom inspector of the SO (maybe is relevant).