Archetype rework in 0.89(.0/2/3) breaks hugo new

Once I figured out you were using things like archetypes/default/index.md instead of archetypes/default.md I tried:

hugo new /blog/2021/hyper-shell/index.md

and got

WARN 2021/11/16 12:44:34 Module "github.com/dnb-org/components/functions" is not compatible with this Hugo version; run "hugo mod graph" for more information.
WARN 2021/11/16 12:44:34 Module "github.com/dnb-org/components/giscus" is not compatible with this Hugo version; run "hugo mod graph" for more information.
WARN 2021/11/16 12:44:34 Module "github.com/dnb-org/components/netlification" is not compatible with this Hugo version; run "hugo mod graph" for more information.
WARN 2021/11/16 12:44:34 Module "github.com/dnb-org/shortcodes/collection" is not compatible with this Hugo version; run "hugo mod graph" for more information.
WARN 2021/11/16 12:44:34 Module "github.com/dnb-org/shortcodes/youtube" is not compatible with this Hugo version; run "hugo mod graph" for more information.
WARN 2021/11/16 12:44:34 Module "github.com/dnb-org/shortcodes/pictures" is not compatible with this Hugo version; run "hugo mod graph" for more information.
Error: from config: failed to resolve output format "security" from site config

It looks to me like the use of directories for config and archetypes is confusing the new archetype code.

Oh, hugo version: hugo v0.89.3-C88CDB56 linux/amd64 BuildDate=2021-11-15T12:17:46Z VendorInfo=gohugoio

Scratch that; it’s occurring for me independent of use of directories for archetypes and config. (But haven’t yet got a public repo to show).

EDIT:

With my repo at

https://github.com/danielfdickinson/hugo-mounted-content-subdir-bug-0-89.git

and rm -rf archetypes (so that it uses the theme archetypes):

I get the same error as

Which is to say it works if I first do hugo mod vendor, but if I don’t I get:

hugo new content/test-docs/test2.md
hugo: collected modules in 1696 ms
Error: could not determine content directory for "content/test-docs/test2.md"

OR

hugo new test-docs/test2.md
Error: could not determine content directory for "test-docs/test2.md"

EDIT: I wonder if Go has changed something that affects the vfs?

@bep What is the best way to capture the info for an issue report on GitHub?