Generally, though, I'm against the arguments of "automation is bad cuz less jobs". I think that might be true in the very short term, but we're never going to have a case where "all possible work is done", because that's a completely malformed premise. There's pretty much an infinite amount of potential work to do.
The short term matters. It's zero comfort to a factory worker who has lost his job if there will be another, better job for him in a year or two. He still needs to eat between now and then, and he can't buy food with pie in the sky promises of future employment.
The reason for AFAIK, my understanding is it is more common for people to be left behind than to transition entirely to a new industry. (That is my memory of seeing some data around that, not saying I'm correct, but that I find it just as plausible to speculate that industrial transitions don't always transition with the same workers.) Perhaps we should talk farming? That is the biggest example pethaps. Some 80% plus of all populations used to do agriculture. The Grapes of Wraith were all about this very topic.
In hindsight, I think they were completely right and I feel kind of lucky that they drilled that in so much, because even into my mid 30's I don't have a ton of trouble or resistance to picking up new things. Sometimes I don't love the way new tech is going [1], but I still try my best to keep up with what's in demand in the industry (generally looking at job boards and looking at their keywords and making sure I have at least a cursory understanding of the stuff they're talking about). I will admit I don't completely love that AI is being used instead of junior engineers in some cases, largely because a lot of AI code is shit or flatout wrong in non-obvious ways, but I still have tried my best to utilize it and learn from it because it's clearly the way that things are going. [2]
I've been hired and lost/quit more desk jobs than anyone I know, and I attribute my ability to find work quickly to this characteristic.
[1] e.g. treating memory like it's infinite, disregarding CPU performance as a means of "getting more shit done", making configurations (arguably) needlessly complicated like Kubernetes, etc.
[2] For example, my latest project has been building an HLS and Icecast "infinite radio station" which picks a random song from my collection, feeds a prompt to OpenAI for DJ chatter in between songs,
I wouldn’t necessarily be opposed to forcing companies to pay some amount per month to people whose jobs were automated away for N years, and/or providing job training for a new career.
As a higher income individual I conversely seem to have a lot of time to study and am not given a constant stream of work I must complete every moment. I also have the benefit of working from home and being able to spend a lot on training and upskilling.
When you are poorer you typically don't get this. The vast majority of your income is spent at the end of the week. Your job gives you zero time to explore and learn more. You likely commute and and may have a second job to make ends meet.
Just saying 'learn to code' here doesn't address the systematic issues.