After upgrading to Hugo .56, I get the following error when running a build:
ERROR 2019/07/27 11:33:45 render of "page" failed: "/Users/brunoamaral/Labs/Digital-Insanity/themes/now-ui/layouts/_default/baseof.html:115:17": execute of template failed: template: _default/single.html:115:17: executing "_default/single.html" at <.Fill>: can't evaluate field Fill in type resource.Resource
Looking at the code, this is what is causing the error:
<img class="img rounded" src="{{ with .Resources.GetMatch "header" }}{{ $image := .Fill "450x150" }}{{ $image.RelPermalink }}{{ end }}" alt="Story header: {{ .Params.title }}">```
I have tried to delete the resources directory, but that didn't work.
Isn’t what you get with the with a slice or array? I would have range inside of that with loop (if I would write it from scratch). The range dot then has .Fill available.
I’m also getting a similar errors on two different projects after upgrading to 0.56.
ERROR 2019/07/27 07:37:28 render of "page" failed: "/Users/projects/layouts/_default/single.html:21:31": execute of template failed: template: _default/single.html:21:31: executing "main" at <.Resize>: can't evaluate field Resize in type resource.Resource
Unfortunately (for you, anway) my issue was a mistake I did when moving the Hugo theme to a module, and not with Hugo itself. I have added a better error message for my situation to help others …
That said,
If your nil issue persists in Hugo 0.56.1, I would guess that you have a non-image file named … header something.