Exactly this. All scenarios now are a loss for Putin:
1. They take Ukraine and spend forever with a ornery neighbour that they have to ceaselessly "pacify";
2. They split Ukraine and see "West Ukraine" join EU/NATO and have a hostile power on their border who they cannot invade again without facing the entire western world;
3. They leave Ukraine in defeat and lose a war against a nation 1/3 their size.
Under 1&2 sanctions continue indefinitely, Europe will be forced to move away from Russian energy reliance weakening Russia as a world power. Once they are weakened, China will have no further use for them and they lose their only meaningful ally.
Under 3, they spend the next few decades climbing back out of sanctions and regaining trust, but only if Putin is no longer there.