@mattiem the two statements are not contradictory - the former only implies that AI can't write an entire piece of software by itself, and the second only implies that it can be used as a tool to aid a human in the writing of software.
That said, I am no longer all that confident that AI can't write software by itself. In the last few years almost every statement of the form "AI can do X but can't do Y" has aged very poorly.