I disagree and believe that quite the opposite is true.
If you think AI will not replace programmers, then maybe you're not that good at programming or AI. You don't understand either well enough to see the big picture.
As a staff SWE who uses a ton of AI tools to massively improve work productivity, I can guarantee you that AI has already taken up many interns and entry-level SWE jobs. My company doesn't even hire entry-level devs anymore. How many more iterations of improvement till we don't need SDE-2s? At the current rate of accelerated improvement, how long before we reach that state?
Think about it from an economic perspective too. Employee costs are one of the highest contributors. Software engineering employees are the costliest after C-suite executives and researchers. It makes a lot of economic sense to automate and make more software engineering jobs redundant.