qml/template: improve error outputs

Change-Id: Ie2680752f5b50fc7808cd982dd02beb15828fe92