Leaf index.md giving me a 404

I’ve been reading and re-reading Page Bundles | Hugo and I can’t figure out what I’m doing wrong. The following is an excerpt from my content directory, and there is nothing else in the test2 or writing directories or subdirectories:

├── test2
│   ├── index.md
│   └── test2a
│       └── index.md
└── writing
    ├── index.md
    └── rdfstandards
        └── index.md

rdfstandards/index.md is a copy of test2a/index.md with a different title.

http://localhost:1313/test2/test2a/ displays that first index.md just fine.

http://localhost:1313/writing/rdfstandards/ gives me “404 page not found.”

Any ideas about why I can’t display rdfstandards/index.md?

A page bundle is either a leaf (a content page without any descendants) or a branch (a section with leaves and/or more branches).

A directory with an index.md file is a leaf bundle.
A directory with an _index.md file is a branch bundle.

Thanks, but I still don’t understand why test2a/index.md displays fine in the browser but but rdfstandards/index.md does not.

A leaf has no children. It’s the end of a branch. Nothing but the leaf (index.md) is rendered.

Isn’t rdfstandards a leaf whose index.md should be rendered?

No, because writing/index.md is a leaf; it is the end of a branch. It, by definition, has no descendants.

If test2 has an index.md file, wouldn’t it also be a leaf, in which case test2a/index.md should not render? (As mentioned above, it does.)

(Also, I tried renaming writing/index.md to writing/_index.md but that didn’t help to get writing/rdfstandards/index.md to render.)

We are failing to communicate. Try this:

git clone --single-branch -b hugo-forum-topic-44144 https://github.com/jmooring/hugo-testing hugo-forum-topic-44144
cd hugo-forum-topic-44144
hugo server

Thanks, especially for making a git branch for me to download and try!

I finally realized that some of the inconsistency I was seeing came from renaming index.md files to _index.md, or vice versa, and maybe seeing the behavior that I wanted right away but not after I restarted hugo. I decided that it would make things simpler to create a new subdirectory of content for things like this instead of putting them in a subdirectory of my existing writing directory.