But obviously some things have changed, so I think it makes sense to ask again.
Personally I am convinced that AI will make it easier and easier to create sufficiently good software without the need of skilled and experienced engineers. It might not be in 5 or 10 years, but I believe it will happen long before my retirement.
To evade the fallout on salary and job opportunities, what are things one can do to prepare? Are there any skills that make one less susceptible to AI replacement? Any fields within engineering (or engineering adjacent) one should get into?
Keep your skills sharp, understand what users want, and look out for your own career when you can. Make hay when the sun shines.
All this isn't to say that the job is even going to be automated. Maybe AI really does just serve to make us better for now! Important to remember that the more well equipped you are cognitively, and the better emotional reasoning (EQ in general) you have, the longer you are going to survive.
We have a long way to go to this future and you're ahead of it already by thinking about it. Don't succumb to anxiety and fear. If this is really what you enjoy doing, keep doing it and keep on your shit.
Perhaps the one counter to this is that a future where AI can displace large swaths of knowledge workers is one where the economy and, by extension, your investments become disrupted in a negative way. But that seems unlikely.