How to know when to change circumstance

I was wondering – is there was a way to tell when it is time to change the circunstance vs changing thoughts? Is it more importnat that we simply “know” or believe the circumstance isnt what makes them happy/sad, or ideally do we successfully manage to create happiness in that situation before leaving at all? Or is there a different question that gets at whether the circumstance can change first without perpetuating old thought patterns?