I keep myself sane by one, as others have said, realizing that developers will still very likely have a better understanding of how to use AI to create stable and maintainable software; There's more to software development than just coding.
Second, I am increasingly becoming aware that I'm more than my white-collar output, which I feel like many devs struggle with specifically since programming is also many devs personal hobby. It's a bit depressing when you have an idea for a side project to solve a personal problem and Opus can shit it out in 5 minutes. But I've also realized it frees up a lot of time. I can realize a lot of those small automations that were piling up on my backlog now. Ideas that I dreamed up but never had the time to personally implement. I can write more. I can read more small blogs by real humans with real opinions. I'm learning more about networking and selfhosting, topics I never had much time for because I spent my little free time on coding projects. And I will probably also get back into game development since that's where creativity and expression, as opposed to implementation, really shines, and that's something that I don't see AI taking away from us very soon.
As for the economical impact, well, lol lmao we'll have to cross that bridge when we get there. I just think that personally by the time I myself am affected by this problem, we have a global crisis anyway so it's not really like I can personally prepare for it.