Looks like that Hugo doesn’t like the delimit
function in a single.html
that makes use of if eq .Section
to render different things according to category.
Anyway I managed to make the error go away by using delimit
like this at the beginning of my template:
<section class='wrapper{{if eq .Section "art-fairs"}} permalink {{ delimit .Params.tags " " }}{{end}}{{if eq .Section "artists"}} permalink artists{{end}}{{if eq .Section "exhibitions"}} permalink{{end}}'>