For a while now, it has been clear to many socioeconomic commentators and politicians in Germany that the political Vernunft displayed by CDU and SPD in the last years coupled with their joint efforts to occupy the middle of the political spectrum has been creating voids both left of SPD and right of CDU which provide fruitful ground for both left and right wing populism to grow.
This largely explains the growth of Die Linke but also of the AfD and it also explains why CDU/CSU have an advantage over SPD: the CSU has been trying to capture some of the right wing sentiment left untapped by CDU thus also contributing to moderating the rise of the AfD by the way.
My paper Explaining Opinion polarisation with opinion copulas explains how opposing AfD the wrong way helps it actually flair up. The best way to extinguish the AfD is to allow mild, nuanced variants of its positions to flourish across the entire political spectrum (“de-copulating” the debate) even if they are wrong. Accusing people that their views are similar to AfD creates a reservoir of suppressed people some of whom then have nowhere to go but choose AfD as their refuge.
Consequently both the SPD and the CDU need to allow euro-skepticism to exist within their ranks. The debate will still allow them to be (as they should) pro European in the end.