Panic in library::content::page::Page::serialize_assets
on Windows
#1939
Labels
bug
done in pr
Already done in a PR
Need Windows help
We need someone using Windows to help us with this issue
Bug Report
Environment
Zola version: v0.16
Windows 10.
Expected Behavior
My site builds successfully
Current Behavior
I get a panic while building/serving my site at this line.
Ran git bisect, first bad commit is 0f23a40
Doing some
println!
debugging on my end, the bug comes from that there's a mismatch between forward and backwards slashes in theself.file.path
and thebase_path
. E.g.self.file.path: "//?/C:/Users/tollyx/dev/tollyx.gitlab.io/content/old\\a-rat-betwixt\\index.md"
vsbase_path: "\\\\?\\C:\\Users\\tollyx\\dev\\tollyx.gitlab.io"
.I was able to fix it locally by moving the
.replace('\\', "/")
at the start ofSite::load
to the start ofSite::new
, so that the modified path with forward slashes is what gets stored as the base path inside the site struct. But I do not know if that's the solution we'd want for this.Step to reproduce
Clone https://gitlab.com/tollyx/tollyx.gitlab.io and run
zola build
orzola serve
on windows.The text was updated successfully, but these errors were encountered: