capture exception parsing tmpl file