Skip to content

WARNING: calling (isset %!q(<nil>) "taxonomycloud") with unsupported collection type "invalid" (<nil>) will always return false. #607

@mhansen

Description

@mhansen

After updating Graphviz's Docsy (https://gitlab.com/graphviz/graphviz.gitlab.io) to the latest Docsy version, I get this error when running:

WARNING: calling IsSet with unsupported type "invalid" (<nil>) will always return false.                                                                                                                                                                                                                                                                                    

Not very useful, so I added some more logging to track down the caller in gohugoio/hugo#8668, which yields:

WARNING: calling (isset %!q(<nil>) "taxonomycloud") with unsupported collection type "invalid" (<nil>) will always return false.
WARNING: calling (isset %!q(<nil>) "taxonomypageheader") with unsupported collection type "invalid" (<nil>) will always return false.

The culprits:

This isn't an error in the output: if taxonomy isn't set in the config.toml, then no taxonomy is output, as expected. But it is a bit of warning noise for older users upgrading, or new users who deleted the taxonomy section.

How about we check if .Site.Params.Taxonomy is defined before looking to see if it has values set inside it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions