Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
partialCached slows down Hugo (much) #2935
In the footer of each page, I reference the following partial:
That partial contains:
Now when I try to build Hugo (
Now if I don't use
And I don't change anything else in my theme, then the Hugo build time is less than 2 seconds:
I of course referenced the
To help troubleshoot, the issue also happens when I use:
So it doesn't seem to be caused by using an unique cache key.
That seems to suggest that one of the functions used in the partial don't work nicely with
To rule out even more, on my pages I used this:
Now when I change that to
Then the same problem happens (Hugo remains stuck on 'Started building sites...'). So it doesn't seem to be caused by a cached partial that references a cached partial.
If you have other ideas I can test, let me know.
added a commit
Jan 14, 2017
(1) That might be, I'm using Windows 7 SP 1 (64bit) with Hugo 64 bit.
(2) It's unfortunately not on Github (it's a paid membership kind of site).
(Thanks for the quick reply, by the way. And that even during the weekend. :) )
My previous step to reproduce listed above might be incorrect. After I removed all
Now the problem did not happen.
Optimistically, I re-introduced my second
And then the problem re-appeared.
So I took these steps:
The output for these two steps is:
Here at 8:42:02 I made
When I build Hugo to disk (
This error happens with the behaviour described above: creating a cached partial that's referenced in
Let me know if I can help by testing out some ideas.
I can replicate the same issue on another site of mine. If it helps, I can upload a zip file with that site here. (It's on Bitbucket so not publicly browsable.)
I'm a little doubtful if I should do that already, because I don't want to give the impression that this issue is very urgent for me (it's not) and I don't want to provide even more stuff to go through. That might be offputting and adding more work then needed. So let me know what would help you best.
Please do, it is the only (practical) way we can fix this -- this is not at the top of my (or others) list, but the zip file will wait there for someone to pick up.