Site keeps throwing render errors

I decided to work on my site the other day and when tried to run hugo server, I got this error:

ERROR render of "page" failed: execute of template failed: html/template:_default/single.html:44:14: no such template "_internal/google_analytics_async.html"
ERROR render of "term" failed: execute of template failed: html/template:_default/list.html:44:14: no such template "_internal/google_analytics_async.html"
Total in 64 ms
Error: error building site: render: failed to render pages: render of "home" failed: execute of template failed: html/template:index.html:44:14: no such template "_internal/google_analytics_async.html"

I figured that updating the theme would fix the issue. I ran git submodule update --remote --merge to update the theme, but I’m still getting the render error. Any ideas? I’m using Hugo 0.128.2.

Here is my site: https://gitpi.us/
The repo for my site is here: John Paul Wohlscheid / gitpius · GitLab

Try hugo extended v0.116.0 .

Remove google_analytics_async.html in your templates since your website don’t use it.

just for clarification:

The theme has been updated already and using the current version won’t throw the error.

I would not remove that code, but merge theme changes back to your customization.

  • you customized the delivered baseof.html by overriding it in your own layouts folder.
  • you local copies of files won’t be updated when updating the theme
  • whenever you update the theme you will have to reapply the theme changes to your copy

hint:
You have two more themes in your themes folder (directly committed not as submodule)
maybe you want to remove that to keep your repo clean in case they are not needed anymore

I’m not sure how to do that.

  1. The themes file is in themes/binario/layouts/_default/baseof.html
  2. Your file is in layouts/_default/baseof.html
  • backup your version
  • copy (1) to your layouts overwriting (2)
  • compare your backup with the new one
    • reapply your changes

if i got it right the only change you made was adding {{ partial "track" . }} about line 6/7.
so just readd that after line 5.