Config's permalinks not working since updating

I was using Hugo 0.20 or 0.21 and everything was working fine. I came across the new 0.27 version with support to related content and I wanted to add this to my blog. So I updated hugo from code to latest version, 0.28-dev that I built yesterday.

After building the site, I saw that my permalinks are not used anymore. I would have urls like these: “http://something.com/2017/09/post-slug”. The generated site does not create folder for years and month. I have changed nothing inside my config nor my content files. This is my config file for my dev environment:

baseurl = "http://localhost:1313/"
languageCode = "fr-CA"
title = "42 Bières"
theme = "blg"
Paginate = 12
PaginatePath = "page"
Canonifyurls = true
RemovePathAccents = true

[author]
  name = "Sébastien Leclerc Lavallée"

[permalinks]
  post = "/:year/:month/:slug/"
  page = "/:slug/"

This is part of my front matter for each post:

date: 2017-03-21 02:00:00 -0500
publishDate: 2017-03-21 02:00:00 -0500
layout: post

Is there something that changed recently that I am now aware of? I have read pretty much all release note and didn’t find anything.

Thanks a lot!

1 Like
  • What does it create?
  • Any errors in the log?
  • Can you share the source of this site?

It create all the lists (taxonomy, pagination) and all pages are working fine. I can access them. All the single html file for posts are not created.

I have enabled logging and I see this:

WARN 2017/09/19 19:20:36 No translation bundle found for default language "en"
WARN 2017/09/19 19:20:36 Translation func for language en not found, use default.
WARN 2017/09/19 19:20:36 i18n not initialized, check that you have language file (in i18n) that matches the site language or the default language.
Started building sites ...
INFO 2017/09/19 19:20:36 found taxonomies: map[string]string{"category":"category", "tag":"tag"}
WARN 2017/09/19 19:20:36 [en] Unable to locate layout for "page": [post/post.html.html post/post.html _default/post.html.html _default/post.html theme/post/post.html.html theme/post/post.html theme/_default/post.html.html theme/_default/post.html]

and

WARN 2017/09/19 19:20:37 [en] Unable to locate layout for "taxonomyTerm": [taxonomy/category.terms.en.html.html taxonomy/category.terms.html.html taxonomy/category.terms.en.html taxonomy/category.terms.html _default/terms.en.html.html _default/terms.html.html _default/terms.en.html _default/terms.html indexes/indexes.en.html.html indexes/indexes.html.html indexes/indexes.en.html indexes/indexes.html theme/taxonomy/category.terms.en.html.html theme/taxonomy/category.terms.html.html theme/taxonomy/category.terms.en.html theme/taxonomy/category.terms.html theme/_default/terms.en.html.html theme/_default/terms.html.html theme/_default/terms.en.html theme/_default/terms.html theme/indexes/indexes.en.html.html theme/indexes/indexes.html.html theme/indexes/indexes.en.html theme/indexes/indexes.html]

and

WARN 2017/09/19 19:20:37 [en] Unable to locate layout for "taxonomyTerm": [taxonomy/tag.terms.en.html.html taxonomy/tag.terms.html.html taxonomy/tag.terms.en.html taxonomy/tag.terms.html _default/terms.en.html.html _default/terms.html.html _default/terms.en.html _default/terms.html indexes/indexes.en.html.html indexes/indexes.html.html indexes/indexes.en.html indexes/indexes.html theme/taxonomy/tag.terms.en.html.html theme/taxonomy/tag.terms.html.html theme/taxonomy/tag.terms.en.html theme/taxonomy/tag.terms.html theme/_default/terms.en.html.html theme/_default/terms.html.html theme/_default/terms.en.html theme/_default/terms.html theme/indexes/indexes.en.html.html theme/indexes/indexes.html.html theme/indexes/indexes.en.html theme/indexes/indexes.html]

Other than that, there is not error when I build. Those warnings and a lot of info for alias stuff. Nothing here.

I also tried with macOS homebrew version 0.27.1 on my development machine and I have the same problem.

I managed to find what was causing the problem! Hurray!

In each of my post’s front matter, I had that line:
layout: post

Removing this fix my issue.

Thanks!

My hugo version is 0.48, my site config’s peralnks not working,

title: 液压绞车钢索的限制/改装
date: 2018-09-12
effdate: 2010-01-06
publishDate: 2017-03-21

with setting:
permalinks: /:year/:month/:title/

My .md files are derectly located in content folder.