After updating to the most current version, when I try to rebuild (and without changing the customizations), I get the following error when running hugo
:
Started building sites ...
panic: reflect: Zero(nil) [recovered]
panic: reflect: Zero(nil) [recovered]
panic: reflect: Zero(nil)
goroutine 119 [running]:
text/template.errRecover(0xc42025f830)
/usr/local/go/src/text/template/exec.go:146 +0x62
panic(0xacae60, 0xc4202a11a0)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
text/template.errRecover(0xc42025eb38)
/usr/local/go/src/text/template/exec.go:146 +0x62
panic(0xacae60, 0xc4202a11a0)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
reflect.Zero(0x0, 0x0, 0x0, 0xaedfe0, 0xc42031f608)
/usr/local/go/src/reflect/value.go:2122 +0x134
text/template.(*state).validateType(0xc42025eab8, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf316a0)
/usr/local/go/src/text/template/exec.go:697 +0x700
text/template.(*state).evalArg(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0x0, 0x0, 0xf2c580, 0xc42028bbd0, 0x8, 0x5dc1acbc9fb65f57, ...)
/usr/local/go/src/text/template/exec.go:746 +0x870
text/template.(*state).evalChainNode(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xc4202f4a00, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
/usr/local/go/src/text/template/exec.go:502 +0xf2
text/template.(*state).evalArg(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xf316a0, 0xaedfe0, 0xf2c220, 0xc4202f4a00, 0x2, 0xc4202a1058, ...)
/usr/local/go/src/text/template/exec.go:750 +0x93a
text/template.(*state).evalCall(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xaea6e0, 0xbef4b8, 0x13, 0xf2c280, 0xc4202f6db0, 0xc42026392e, ...)
/usr/local/go/src/text/template/exec.go:643 +0x279
text/template.(*state).evalFunction(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xc4202f6de0, 0xf2c280, 0xc4202f6db0, 0xc4202a90a0, 0x2, 0x2, ...)
/usr/local/go/src/text/template/exec.go:536 +0x18e
text/template.(*state).evalCommand(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xc4202f6db0, 0x0, 0x0, 0x0, 0xaedfe0, 0xc4201e74e0, ...)
/usr/local/go/src/text/template/exec.go:433 +0x6cd
text/template.(*state).evalPipeline(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xc42028bb80, 0xac5b60, 0xc4202a1068, 0x8e)
/usr/local/go/src/text/template/exec.go:406 +0xf2
text/template.(*state).walk(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xf2c100, 0xc4202f6f00)
/usr/local/go/src/text/template/exec.go:232 +0x55a
text/template.(*state).walk(0xc42025eab8, 0xbb1460, 0xc4202b0600, 0x16, 0xf2c460, 0xc4202f6a50)
/usr/local/go/src/text/template/exec.go:240 +0x139
text/template.(*Template).execute(0xc4202f4880, 0xf21e20, 0xc420018700, 0xbb1460, 0xc4202b0600, 0x0, 0x0)
/usr/local/go/src/text/template/exec.go:195 +0x20a
text/template.(*Template).Execute(0xc4202f4880, 0xf21e20, 0xc420018700, 0xbb1460, 0xc4202b0600, 0xc42025eba0, 0xc4202cfe40)
/usr/local/go/src/text/template/exec.go:178 +0x53
html/template.(*Template).Execute(0xc4202f69f0, 0xf21e20, 0xc420018700, 0xbb1460, 0xc4202b0600, 0xc420483590, 0x25)
/usr/local/go/src/html/template/template.go:120 +0x8c
github.com/gohugoio/hugo/tpl/partials.(*Namespace).Include(0xc4202347b0, 0xc4202ba192, 0x11, 0xc4202a0ec0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0)
/Users/bep/go/src/github.com/gohugoio/hugo/tpl/partials/partials.go:73 +0x3fa
github.com/gohugoio/hugo/tpl/partials.(*Namespace).Include-fm(0xc4202ba192, 0x11, 0xc4202a0ec0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0)
/Users/bep/go/src/github.com/gohugoio/hugo/tpl/partials/init.go:32 +0x63
reflect.Value.call(0xaf82c0, 0xc420236fd0, 0x13, 0xbb4d41, 0x4, 0xc420483530, 0x2, 0x2, 0xf316a0, 0xb079c0, ...)
/usr/local/go/src/reflect/value.go:434 +0x91f
reflect.Value.Call(0xaf82c0, 0xc420236fd0, 0x13, 0xc420483530, 0x2, 0x2, 0xf2c2e0, 0xc4202bdb40, 0xbb1460)
/usr/local/go/src/reflect/value.go:302 +0xa4
text/template.(*state).evalCall(0xc42025f7b0, 0xbb1460, 0xc4202b0600, 0x16, 0xaf82c0, 0xc420236fd0, 0x13, 0xf2c280, 0xc4202d37d0, 0xc4202ba189, ...)
/usr/local/go/src/text/template/exec.go:668 +0x51f
text/template.(*state).evalFunction(0xc42025f7b0, 0xbb1460, 0xc4202b0600, 0x16, 0xc4202d3800, 0xf2c280, 0xc4202d37d0, 0xc4202cf3c0, 0x3, 0x4, ...)
/usr/local/go/src/text/template/exec.go:536 +0x18e
text/template.(*state).evalCommand(0xc42025f7b0, 0xbb1460, 0xc4202b0600, 0x16, 0xc4202d37d0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
/usr/local/go/src/text/template/exec.go:433 +0x6cd
text/template.(*state).evalPipeline(0xc42025f7b0, 0xbb1460, 0xc4202b0600, 0x16, 0xc4202b9f40, 0x0, 0x0, 0x98)
/usr/local/go/src/text/template/exec.go:406 +0xf2
text/template.(*state).walk(0xc42025f7b0, 0xbb1460, 0xc4202b0600, 0x16, 0xf2c100, 0xc4202d3830)
/usr/local/go/src/text/template/exec.go:232 +0x55a
text/template.(*state).walk(0xc42025f7b0, 0xbb1460, 0xc4202b0600, 0x16, 0xf2c460, 0xc4202d3620)
/usr/local/go/src/text/template/exec.go:240 +0x139
text/template.(*Template).execute(0xc4202cf280, 0xf21e20, 0xc4200a5ce0, 0xbb1460, 0xc4202b0600, 0x0, 0x0)
/usr/local/go/src/text/template/exec.go:195 +0x20a
text/template.(*Template).Execute(0xc4202cf280, 0xf21e20, 0xc4200a5ce0, 0xbb1460, 0xc4202b0600, 0xc420234030, 0xc00)
/usr/local/go/src/text/template/exec.go:178 +0x53
html/template.(*Template).Execute(0xc4202d35c0, 0xf21e20, 0xc4200a5ce0, 0xbb1460, 0xc4202b0600, 0x9, 0xc420438490)
/usr/local/go/src/html/template/template.go:120 +0x8c
github.com/gohugoio/hugo/tpl.(*TemplateAdapter).Execute(0xc420173930, 0xf21e20, 0xc4200a5ce0, 0xbb1460, 0xc4202b0600, 0xc420173930, 0x2)
<autogenerated>:3 +0x75
github.com/gohugoio/hugo/hugolib.(*Site).renderForLayouts(0xc4200e0500, 0xbc12f4, 0xc, 0xbb1460, 0xc4202b0600, 0xf21e20, 0xc4200a5ce0, 0xc420438400, 0xc, 0x10, ...)
/Users/bep/go/src/github.com/gohugoio/hugo/hugolib/site.go:1975 +0xb8
github.com/gohugoio/hugo/hugolib.(*Site).renderAndWritePage(0xc4200e0500, 0xbb7248, 0x5, 0xc4201afee0, 0x16, 0xc4202b0600, 0xc420438400, 0xc, 0x10, 0x0, ...)
/Users/bep/go/src/github.com/gohugoio/hugo/hugolib/site.go:1915 +0xff
github.com/gohugoio/hugo/hugolib.pageRenderer(0xc4200e0500, 0xc4203191a0, 0xc420318fc0, 0xc4204991b0)
/Users/bep/go/src/github.com/gohugoio/hugo/hugolib/site_render.go:122 +0x7de
created by github.com/gohugoio/hugo/hugolib.(*Site).renderPages
/Users/bep/go/src/github.com/gohugoio/hugo/hugolib/site_render.go:44 +0x156
Unfortunately, the site I'm working on is in a private repo, so can't give a reproducible example. Just wanted to bring this up to see if there's some best practice so that I can avoid this in the future. For now, I'll just checkout the older version.