And then came the whole AI craze. 2017 Tensor Flow 1.0 was released and 2018 popularity of Python started going off the roof, but not in one step, but still incrementally (though less constant than before 2008).

The boost in Python's popularity from 2017 onwards is due to the NumPy and SciPy libraries, which were used for "Data Science". The AI craze did not start until later.

One of Python's strengths is the availability of useful libraries ("batteries included") combined with a simple syntax, which enable people to get their job done.