Have you tried the new chat template Google released recently? It’s supposed to address this and enable reasoning content preservation. I have not tried it myself but am hoping it does the trick, since Gemma is great model otherwise.
Yeah, Gemma is not the best for coding I guess. qwen must be better