zola icon indicating copy to clipboard operation
zola copied to clipboard

Certain pages stopped rendering with 0.16.0

Open scouten opened this issue 2 years ago • 6 comments

Bug Report

Environment

MacOS version: 12.2.1 Rust version: 1.61.0 Zola version: 0.16.0

Site source available at https://github.com/scouten/146parks.blog. Problem reproduces with head revision as of this writing (8be8bdb).

Expected Behavior

When running with zola serve, the pages http://127.0.0.1:1111/todo and http://127.0.0.1:1111/map should appear.

Current Behavior

The above listed pages are not rendered and fall back to the 404 page instead.

Step to reproduce

  1. Download https://github.com/scouten/146parks.blog.
  2. Run zola serve from root of repo.3.
  3. Browse to http://127.0.0.1:1111/todo and http://127.0.0.1:1111/map.

I ran git bisect and it appears that #1827 is where this change was introduced.

scouten avatar Jul 21 '22 04:07 scouten

The checkout of the repo fails because it's asking LFS credentials

Keats avatar Jul 21 '22 09:07 Keats

@Keats can you clone via GIT_LFS_SKIP_SMUDGE=1 git clone https://github.com/scouten/146parks.blog?

🎩 tip: https://stackoverflow.com/questions/42019529/how-to-clone-pull-a-git-repository-ignoring-lfs

scouten avatar Aug 08 '22 04:08 scouten

It does say the following:

Warning: 2 page(s) ignored (missing date or weight in a sorted section):
Warning: - /Users/vincent.prouillet/Code/pulls/146parks.blog/content/todo.md
Warning: - /Users/vincent.prouillet/Code/pulls/146parks.blog/content/map.md

which is a legit issue as they both don't have weights?

Keats avatar Aug 08 '22 07:08 Keats

That's intentional; they're not in the "sequence" for that section (which is almost the entire site).

Prior to the commit I mentioned, they got rendered anyway. I saw the warning, but the site still rendered the way I wanted it to. (See https://146parks.blog/map/, as an example.)

scouten avatar Aug 08 '22 20:08 scouten

I could probably hack this by giving them a negative weight and ignoring that on the section render.

scouten avatar Aug 08 '22 20:08 scouten

The fact that it was rendering before was kind of a bug sadly :/

Keats avatar Aug 08 '22 21:08 Keats

That makes sense. I'll accept this as an as-designed and formerly-buggy behavior.

As noted in the commit mentioned just above, I've found a workaround that lets me use the current release of Zola, so I'll withdraw the ticket. Thanks for taking a look!

scouten avatar Aug 15 '22 18:08 scouten

I ran into this change when I went to update my blog today.

The fact that it was rendering before was kind of a bug sadly :/

Obligatory XKCD: https://xkcd.com/1172/

I thought this was a feature, actually :joy:. It was really nice, I thought, to be able to have my blog posts live at https://domain.com/<post-slug> along side my https://domain.com/about/ page which wasn't in the sequence of posts and was linked to through my site header instead of the section list on my homepage.

Are you open to considering this bug, or an alternative, as a feature for a future release? :smile:

Edit: I was able to find a different workaround for my needs. Maybe this suffices long term? Could use documentation perhaps.

keawade avatar Oct 28 '22 21:10 keawade