Trouble Viewing Notes Page After Hugo Upgrade

Hi, My notes pages were showing up before Hugo v0.122.0+extended. However, after upgrading to v0.123.0+extended or later versions, I can’t seem to view the notes page anymore when deploying. Strangely, I can still see the notes page when running the website locally.

Here’s the command I’m using for localhost:

rm -rf public/ resources/ && hugo mod clean && hugo mod tidy && hugo mod get -u ./... && hugo --gc --minify --cleanDestinationDir && hugo server --disableFastRender

And here’s my .gitlab-ci.yml:

variables:
  HUGO_VERSION: latest
  GIT_SUBMODULE_STRATEGY: recursive
  GIT_DEPTH: 0
  GIT_STRATEGY: clone

# All available Hugo versions are listed here: https://gitlab.com/pages/hugo/container_registry
image: registry.gitlab.com/pages/hugo/hugo_extended:${HUGO_VERSION}

pages:
  script:
    # Install brotli
    - apk update
    - apk add brotli

    # Build
    - hugo mod clean
    - hugo mod tidy
    - hugo mod get -u ./...
    - hugo --gc --minify --cleanDestinationDir

    # Compress
    - find public -type f -regex '.*\.\(css\|html\|js\|txt\|xml\)$' -exec gzip -f -k {} \;
    - find public -type f -regex '.*\.\(css\|html\|js\|txt\|xml\)$' -exec brotli -f -k {} \;
  artifacts:
    paths:
    - public
  only:
  - main

Hugo env:

hugo v0.123.7-312735366b20d64bd61bff8627f593749f86c964+extended darwin/arm64 BuildDate=2024-03-01T16:16:06Z VendorInfo=gohugoio
GOOS="darwin"
GOARCH="arm64"
GOVERSION="go1.22.0"
github.com/sass/libsass="3.6.5"
github.com/webmproject/libwebp="v1.3.2"

This is my repo: MyArchieve

Any insights on why the notes page is not visible after deployment but works fine locally?

Can you please provide a link to your project repository instead of to the live site?

Ohh I am sorry, I thought I did. Here is the repo

You have a page collision that is in no way related to v0.123.x.

hugo --printPathWarnings

WARN  Duplicate target paths: /notes/index.html (2)

You have:

  • themes/archieve/content/notes
  • themes/archieve/content/pages/notes.md

Then this in your site configuration:

permalinks:
  posts: "/:filename/"
  pages: "/:filename/"

Which causes both pages to be written to public/notes/index.html. The one that was rendered last wins, and the rendering order is indeterminate due to concurrency.

As to what is rendered (or not rendered) on the notes page, your entire site is… unusual:

  • You have implemented your own taxonomy system instead of using Hugo’s
  • You are repeating yourself by not using the base/block template model
  • You’ve assigned type “note” to all items in the “notes” (plural) directory, and I have no idea why

Due to the above and other unusual constructs, this isn’t something that I’m going to spend any time on.