Skip to content

Encountering "The system cannot find the path specified" error when using nul as taxonomy on Windows. #12640

Open
@razonyang

Description

@razonyang

What version of Hugo are you using (hugo version)?

$ hugo version
hugo v0.128.1-0ff542b4b9cc7b5cb425bbab8bdb5aace81d0c03+extended windows/amd64 BuildDate=2024-07-02T06:46:41Z VendorInfo=gohugoio

Does this issue reproduce with the latest release?

Yes

Reproduce Steps

$ hugo new site hugo-test1

$ cd hugo-test1

Create content/foo.md with the following content.

---
title: Foobar
tags:
  - "Nul"
---

And then build site.

$ hugo
Start building sites …
hugo v0.128.1-0ff542b4b9cc7b5cb425bbab8bdb5aace81d0c03+extended windows/amd64 BuildDate=2024-07-02T06:46:41Z VendorInfo=gohugoio

WARN  found no layout file for "html" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN  found no layout file for "html" for kind "taxonomy": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN  found no layout file for "html" for kind "term": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN  found no layout file for "html" for kind "home": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
Total in 7 ms
Error: error building site: render: failed to render pages: mkdir E:\Workspaces\hugo-test1\public\tags\nul: The system cannot find the path specified.

I'm awared that the issue isn't related to Hugo directly (golang/go#24556), is it possible to handle it in Hugo layer?
For example, rename the nul folder as other on Windows?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions