Hugo is ok on one hosting and throws error on other

hi

I have some strange problem.

Hugo is generating OK on one hosting and throws error on other.

  1. On my local mac (sierra) → OK
  2. On hoster 1 - OK
  3. On my own server (debian 8.10) - ERROR

The error is:
Building sites … ERROR 2018/06/15 11:58:23 Error while rendering “section” in “about/”: html/template:section/main-sidebar-right.html:10:24: no such template “getColumnContent”

The hugo code that is generating the error is here if you would like to test / check:

Thanks in advance for all valuable tips how to solve this problem.

Which version of Hugo is installed on your server?

Sry. I forget to say. On all cases there is the most new Hugo 0.42.1

On the server which is wrong:
Hugo Static Site Generator v0.42.1 linux/amd64 BuildDate: 2018-06-13T10:16:36Z

The output of debug:

DEBUG 2018/06/15 12:55:55 Add template file: name "section/main-sidebar-left.html", baseTemplatePath "_default/baseof.html", path "section/main-sidebar-left.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "section/main-sidebar-right.html", baseTemplatePath "_default/baseof.html", path "section/main-sidebar-right.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "section/main.html", baseTemplatePath "_default/baseof.html", path "section/main.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "index.html", baseTemplatePath "", path "index.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce--content-column.html", baseTemplatePath "", path "partials/ce--content-column.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce--data-file-not-found.html", baseTemplatePath "", path "partials/ce--data-file-not-found.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce--section-header.html", baseTemplatePath "", path "partials/ce--section-header.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce--section.html", baseTemplatePath "", path "partials/ce--section.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce-card.html", baseTemplatePath "", path "partials/ce-card.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce-faq1.html", baseTemplatePath "", path "partials/ce-faq1.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce-grid2col.html", baseTemplatePath "", path "partials/ce-grid2col.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/ce-text.html", baseTemplatePath "", path "partials/ce-text.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/footer.html", baseTemplatePath "", path "partials/footer.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/head.html", baseTemplatePath "", path "partials/head.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/header-breadcrumb.html", baseTemplatePath "", path "partials/header-breadcrumb.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/header-menulang.html", baseTemplatePath "", path "partials/header-menulang.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/header-menumain.html", baseTemplatePath "", path "partials/header-menumain.html"
DEBUG 2018/06/15 12:55:55 Add template file: name "partials/header.html", baseTemplatePath "", path "partials/header.html"
INFO 2018/06/15 12:55:55 Using config file: /var/www/t3base8/hugo/config.yaml
Building sites … INFO 2018/06/15 12:55:55 syncing static files to /var/www/t3base8/hugo/public/
WARN 2018/06/15 12:55:55 No Static directory found
INFO 2018/06/15 12:55:55 found taxonomies: map[string]string{"tag":"tags", "category":"categories"}
INFO 2018/06/15 12:55:55 found taxonomies: map[string]string{"tag":"tags", "category":"categories"}
DEBUG 2018/06/15 12:55:55 Write redirect to main language en:
DEBUG 2018/06/15 12:55:55 creating alias: en redirecting to
INFO 2018/06/15 12:55:55 Alias "en" translated to "en/index.html"
DEBUG 2018/06/15 12:55:55 Render home to "/index.html" with layouts ["page/main.en.html.html" "page/index.en.html.html" "page/home.en.html.html" "page/list.en.html.html" "page/main.html.html" "page/index.html.html" "page/home.html.html" "page/list.html.html" "page/main.en.html" "page/index.en.html" "page/home.en.html" "page/list.en.html" "page/main.html" "page/index.html" "page/home.html" "page/list.html" "main.en.html.html" "index.en.html.html" "home.en.html.html" "list.en.html.html" "main.html.html" "index.html.html" "home.html.html" "list.html.html" "main.en.html" "index.en.html" "home.en.html" "list.en.html" "main.html" "index.html" "home.html" "list.html" "_default/main.en.html.html" "_default/index.en.html.html" "_default/home.en.html.html" "_default/list.en.html.html" "_default/main.html.html" "_default/index.html.html" "_default/home.html.html" "_default/list.html.html" "_default/main.en.html" "_default/index.en.html" "_default/home.en.html" "_default/list.en.html" "_default/main.html" "_default/index.html" "_default/home.html" "_default/list.html"]
DEBUG 2018/06/15 12:55:55 Render section to "/about/index.html" with layouts ["about/main-sidebar-right.en.html.html" "about/about.en.html.html" "about/section.en.html.html" "about/list.en.html.html" "about/main-sidebar-right.html.html" "about/about.html.html" "about/section.html.html" "about/list.html.html" "about/main-sidebar-right.en.html" "about/about.en.html" "about/section.en.html" "about/list.en.html" "about/main-sidebar-right.html" "about/about.html" "about/section.html" "about/list.html" "section/main-sidebar-right.en.html.html" "section/about.en.html.html" "section/section.en.html.html" "section/list.en.html.html" "section/main-sidebar-right.html.html" "section/about.html.html" "section/section.html.html" "section/list.html.html" "section/main-sidebar-right.en.html" "section/about.en.html" "section/section.en.html" "section/list.en.html" "section/main-sidebar-right.html" "section/about.html" "section/section.html" "section/list.html" "_default/main-sidebar-right.en.html.html" "_default/about.en.html.html" "_default/section.en.html.html" "_default/list.en.html.html" "_default/main-sidebar-right.html.html" "_default/about.html.html" "_default/section.html.html" "_default/list.html.html" "_default/main-sidebar-right.en.html" "_default/about.en.html" "_default/section.en.html" "_default/list.en.html" "_default/main-sidebar-right.html" "_default/about.html" "_default/section.html" "_default/list.html"]
DEBUG 2018/06/15 12:55:55 Render section to "/faq/index.html" with layouts ["faq/main-sidebar-left.en.html.html" "faq/faq.en.html.html" "faq/section.en.html.html" "faq/list.en.html.html" "faq/main-sidebar-left.html.html" "faq/faq.html.html" "faq/section.html.html" "faq/list.html.html" "faq/main-sidebar-left.en.html" "faq/faq.en.html" "faq/section.en.html" "faq/list.en.html" "faq/main-sidebar-left.html" "faq/faq.html" "faq/section.html" "faq/list.html" "section/main-sidebar-left.en.html.html" "section/faq.en.html.html" "section/section.en.html.html" "section/list.en.html.html" "section/main-sidebar-left.html.html" "section/faq.html.html" "section/section.html.html" "section/list.html.html" "section/main-sidebar-left.en.html" "section/faq.en.html" "section/section.en.html" "section/list.en.html" "section/main-sidebar-left.html" "section/faq.html" "section/section.html" "section/list.html" "_default/main-sidebar-left.en.html.html" "_default/faq.en.html.html" "_default/section.en.html.html" "_default/list.en.html.html" "_default/main-sidebar-left.html.html" "_default/faq.html.html" "_default/section.html.html" "_default/list.html.html" "_default/main-sidebar-left.en.html" "_default/faq.en.html" "_default/section.en.html" "_default/list.en.html" "_default/main-sidebar-left.html" "_default/faq.html" "_default/section.html" "_default/list.html"]
ERROR 2018/06/15 12:55:55 Error while rendering "section" in "faq/": html/template:section/main-sidebar-left.html:10:24: no such template "getColumnContent"

I am a bit mystified with your site’s structure. Particularly how you define a block template from within a partial.

In your templates the line {{ template "getColumnContent" . }} calls a partial under /partials/ce--content-column.html

Your site builds on my end. But from the error you have on your server it is obvious that Hugo cannot find this template.

How about trying to replace what you already have in your templates with {{ template "/partials/ce--content-column.html" . }}

And let me know if that fixes your issue.

I changed and commited the new version to github.
It works on my local and on hoster 1.
But still problems on my server.
This time its no: such template "partials/ce–content-column.html"

DEBUG 2018/06/15 14:02:37 Add template file: name "section/main-sidebar-left.html", baseTemplatePath "_default/baseof.html", path "section/main-sidebar-left.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "section/main-sidebar-right.html", baseTemplatePath "_default/baseof.html", path "section/main-sidebar-right.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "section/main.html", baseTemplatePath "_default/baseof.html", path "section/main.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "index.html", baseTemplatePath "", path "index.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce--content-column.html", baseTemplatePath "", path "partials/ce--content-column.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce--data-file-not-found.html", baseTemplatePath "", path "partials/ce--data-file-not-found.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce--section-header.html", baseTemplatePath "", path "partials/ce--section-header.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce--section.html", baseTemplatePath "", path "partials/ce--section.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce-card.html", baseTemplatePath "", path "partials/ce-card.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce-faq1.html", baseTemplatePath "", path "partials/ce-faq1.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce-grid2col.html", baseTemplatePath "", path "partials/ce-grid2col.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/ce-text.html", baseTemplatePath "", path "partials/ce-text.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/footer.html", baseTemplatePath "", path "partials/footer.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/head.html", baseTemplatePath "", path "partials/head.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/header-breadcrumb.html", baseTemplatePath "", path "partials/header-breadcrumb.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/header-menulang.html", baseTemplatePath "", path "partials/header-menulang.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/header-menumain.html", baseTemplatePath "", path "partials/header-menumain.html"
DEBUG 2018/06/15 14:02:37 Add template file: name "partials/header.html", baseTemplatePath "", path "partials/header.html"
INFO 2018/06/15 14:02:37 Using config file: /var/www/t3base8/hugo/config.yaml
Building sites … INFO 2018/06/15 14:02:37 syncing static files to /var/www/t3base8/hugo/public/
WARN 2018/06/15 14:02:37 No Static directory found
INFO 2018/06/15 14:02:37 found taxonomies: map[string]string{"tag":"tags", "category":"categories"}
INFO 2018/06/15 14:02:37 found taxonomies: map[string]string{"tag":"tags", "category":"categories"}
DEBUG 2018/06/15 14:02:37 Write redirect to main language en:
DEBUG 2018/06/15 14:02:37 creating alias: en redirecting to
INFO 2018/06/15 14:02:37 Alias "en" translated to "en/index.html"
DEBUG 2018/06/15 14:02:37 Render section to "/de/ueber/index.html" with layouts ["about/main-sidebar-right.de.html.html" "about/about.de.html.html" "about/section.de.html.html" "about/list.de.html.html" "about/main-sidebar-right.html.html" "about/about.html.html" "about/section.html.html" "about/list.html.html" "about/main-sidebar-right.de.html" "about/about.de.html" "about/section.de.html" "about/list.de.html" "about/main-sidebar-right.html" "about/about.html" "about/section.html" "about/list.html" "section/main-sidebar-right.de.html.html" "section/about.de.html.html" "section/section.de.html.html" "section/list.de.html.html" "section/main-sidebar-right.html.html" "section/about.html.html" "section/section.html.html" "section/list.html.html" "section/main-sidebar-right.de.html" "section/about.de.html" "section/section.de.html" "section/list.de.html" "section/main-sidebar-right.html" "section/about.html" "section/section.html" "section/list.html" "_default/main-sidebar-right.de.html.html" "_default/about.de.html.html" "_default/section.de.html.html" "_default/list.de.html.html" "_default/main-sidebar-right.html.html" "_default/about.html.html" "_default/section.html.html" "_default/list.html.html" "_default/main-sidebar-right.de.html" "_default/about.de.html" "_default/section.de.html" "_default/list.de.html" "_default/main-sidebar-right.html" "_default/about.html" "_default/section.html" "_default/list.html"]
DEBUG 2018/06/15 14:02:37 Render home to "/de/index.html" with layouts ["page/main.de.html.html" "page/index.de.html.html" "page/home.de.html.html" "page/list.de.html.html" "page/main.html.html" "page/index.html.html" "page/home.html.html" "page/list.html.html" "page/main.de.html" "page/index.de.html" "page/home.de.html" "page/list.de.html" "page/main.html" "page/index.html" "page/home.html" "page/list.html" "main.de.html.html" "index.de.html.html" "home.de.html.html" "list.de.html.html" "main.html.html" "index.html.html" "home.html.html" "list.html.html" "main.de.html" "index.de.html" "home.de.html" "list.de.html" "main.html" "index.html" "home.html" "list.html" "_default/main.de.html.html" "_default/index.de.html.html" "_default/home.de.html.html" "_default/list.de.html.html" "_default/main.html.html" "_default/index.html.html" "_default/home.html.html" "_default/list.html.html" "_default/main.de.html" "_default/index.de.html" "_default/home.de.html" "_default/list.de.html" "_default/main.html" "_default/index.html" "_default/home.html" "_default/list.html"]
ERROR 2018/06/15 14:02:37 Error while rendering "section" in "about/": html/template:section/main-sidebar-right.html:10:24: no such template "partials/ce--content-column.html"

I would also try eliminating that template function and just call it as a partial.

Like so:
{{ partial "ce--content-column.html" . }}

That worked! :slight_smile: :slight_smile: :slight_smile:
Thanks a lot for your time.