Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sections cause panic, sass isn't processed at all. #1932

Closed
InaccurateTank opened this issue Jul 20, 2022 · 9 comments
Closed

Sections cause panic, sass isn't processed at all. #1932

InaccurateTank opened this issue Jul 20, 2022 · 9 comments
Labels
bug Need Windows help We need someone using Windows to help us with this issue

Comments

@InaccurateTank
Copy link

Bug Report

Environment

Zola version: 0.16.0
OS: Windows 10

Expected Behavior

Sections should be created and sass should be processed.

Current Behavior

Sections currently cause a panic when being created with any children. Console output with backtrace is:

thread 'main' panicked at 'called `Option::unwrap()` on a `None` value', components\content\src\library.rs:312:81
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

As for the sass not being processed, I have nothing. It doesn't throw any errors and simply doesn't get added to ./public.

Step to reproduce

For Sections:

  • Make Folder
  • Add _index.md with frontmatter
  • Add child page

For Sass:
Literally just any file at all in the respective folder. It doesn't do anything.

@Keats Keats added the bug label Jul 20, 2022
@Keats
Copy link
Collaborator

Keats commented Jul 20, 2022

sass should be processed.

Do you have it turned on in config.toml ? /~https://github.com/getzola/zola/blob/master/docs/config.toml#L5

As for the panic, it might be a Windows only bug as I can't reproduce it in on macos. Anyone on Windows willing to help debugging it?

@Keats Keats added the Need Windows help We need someone using Windows to help us with this issue label Jul 20, 2022
@InaccurateTank
Copy link
Author

InaccurateTank commented Jul 20, 2022

Do you have it turned on in config.toml ? /~https://github.com/getzola/zola/blob/master/docs/config.toml#L5

I do yes, and the reason I'm adding it here is because it works 100% fine if I downgrade to 0.15.3. Did a reinstall to be absolutely sure.

On a second, closer inspection of the output it seems like the paths are mangled? On 0.15.3 the output is this:

Building site...
Checking all internal links with anchors.
> Successfully checked 0 internal link(s) with anchors.
-> Creating 2 pages (0 orphan) and 1 sections

Listening for changes in E:\[path snip]\site-source{config.toml, content, sass, static, templates}
Press Ctrl+C to stop

Web server is available at http://127.0.0.1:1111
Change detected @ 2022-07-19 23:33:25
-> Sass file changed E:\[path snip]\site-source\sass\assets\css\main.scss
Done in 15ms.

On 0.16.0 It's this.

Building site...
Checking all internal links with anchors.
> Successfully checked 0 internal link(s) with anchors.
-> Creating 2 pages (2 orphan) and 1 sections
Done in 117ms.

Web server is available at http://127.0.0.1:1111

Listening for changes in \\?\E:\[path snip]\site-source\{config.toml,content,sass,static,templates}
Press Ctrl+C to stop

Change detected @ 2022-07-19 23:34:40
-> Sass file changed \\?\E:\[path snip]\site-source\sass\assets\css\main.scss
Done in 0ms.

@Keats
Copy link
Collaborator

Keats commented Jul 20, 2022

Can the site be shared? I don't think we changed anything regarding Sass in 0.16 :/

@InaccurateTank
Copy link
Author

The site source is here: /~https://github.com/InaccurateTank/site-source
It deploys correctly which probably confirms this is a windows thing?

@Keats
Copy link
Collaborator

Keats commented Jul 20, 2022

Yep, works fine on my macbook. I'll need someone with a Windows machine to figure out what's happening.

@swiftcoder
Copy link
Contributor

For the SASS issue it looks like we've afoul of rust-lang/glob#111

@korrat
Copy link

korrat commented Jul 30, 2022

Another issue, which seems to be related. When adding an empty _index.md directly under content, I get the following error.

Building site...
Error: Failed to build the site
Error: Found path collisions:
- `/` from files ["//?/E:/Programmieren/websites/blog/content/_index.md", "\\\\?\\E:\\Programmieren\\websites\\blog\\content\\_index.md"]

@Keats
Copy link
Collaborator

Keats commented Jul 30, 2022

It should be fixed in the next branch if you want to try

@korrat
Copy link

korrat commented Jul 31, 2022

On my Windows box, I can confirm that next fixes the issue with the top-level _index.md, and rust-lang/glob#112 fixes Sass files not being compiled. It seems that next also fixes the issue when generating sections, but I'm unable to reproduce the issue on the master branch.

@Keats Keats closed this as completed Aug 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Need Windows help We need someone using Windows to help us with this issue
Projects
None yet
Development

No branches or pull requests

4 participants