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

0.64: process hangs up on "Building sites" line #6789

Open
artch opened this issue Jan 23, 2020 · 11 comments
Open

0.64: process hangs up on "Building sites" line #6789

artch opened this issue Jan 23, 2020 · 11 comments

Comments

@artch
Copy link

@artch artch commented Jan 23, 2020

What version of Hugo are you using (hugo version)?

$ hugo version
Hugo Static Site Generator v0.63.0/extended windows/amd64 BuildDate: unknown

My site is unable to build using Hugo 0.63 extended version. It worked fine on 0.62.2.

Building sites … ERROR 2020/01/23 16:16:37 [BUG] Got panic:
runtime error: invalid memory address or nil pointer dereference
goroutine 110 [running]:
runtime/debug.Stack(0x1e639c8, 0x2, 0xc006bb5600)
	/usr/local/go/src/runtime/debug/stack.go:24 +0xa4
github.com/gohugoio/hugo/hugolib.newPageContentOutput.func1.1(0xc006bb5f20, 0xc0015ef050)
	/root/project/hugo/hugolib/page__per_output.go:93 +0xce
panic(0x1bec8c0, 0x19a2f70)
	/usr/local/go/src/runtime/panic.go:679 +0x1c0
github.com/gohugoio/hugo/tpl/tplimpl.(*templateNamespace).parse(0x0, 0xc00afe5740, 0x35, 0xc012522000, 0xb899, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	/root/project/hugo/tpl/tplimpl/template.go:797 +0x55
github.com/gohugoio/hugo/tpl/tplimpl.(*templateHandler).AddLateTemplate(0xc0008252c0, 0xc00afe5740, 0x35, 0xc012522000, 0xb899, 0x0, 0x0)
	/root/project/hugo/tpl/tplimpl/template.go:280 +0x195
github.com/gohugoio/hugo/hugolib.(*pageContentOutput).addSelfTemplate(0xc0047c5dc0, 0xc003b1be80, 0x31)
	/root/project/hugo/hugolib/page__per_output.go:433 +0x173
github.com/gohugoio/hugo/hugolib.newPageContentOutput.func1(0x22beb80, 0xc01100db00)
	/root/project/hugo/hugolib/page__per_output.go:200 +0x5c3
github.com/gohugoio/hugo/hugolib.newPageContentOutput.func2(0x22e7040, 0xc0111b5b00, 0x1e63941, 0x1, 0x4, 0xc0009abfa8)
	/root/project/hugo/hugolib/page__per_output.go:215 +0x2d
github.com/gohugoio/hugo/lazy.(*Init).withTimeout.func1(0xc003f36070, 0x22e7040, 0xc0111b5b00, 0xc0111b5b60)
	/root/project/hugo/lazy/init.go:177 +0x4e
created by github.com/gohugoio/hugo/lazy.(*Init).withTimeout
	/root/project/hugo/lazy/init.go:176 +0x115
Built in 3272 ms
@bep

This comment has been minimized.

Copy link
Member

@bep bep commented Jan 23, 2020

Please revise the title of this issue (I assume no one died) and provide more detail as to "what".

@bep bep changed the title Fatal regression on 0.63 0.63: "late templates" fails with a nil-pointer Jan 23, 2020
@bep bep added this to the v0.63.1 milestone Jan 23, 2020
@bep

This comment has been minimized.

Copy link
Member

@bep bep commented Jan 23, 2020

Hey, the stacktrace tells me the "what" but not the "why", and I'm not able to reproduce this.

I suspect that I need to see your site's source to be able to track down this issue.

@bep

This comment has been minimized.

Copy link
Member

@bep bep commented Jan 23, 2020

I'm guessing you have multiple languages with some plain HTML templates inside /content. Maybe.

bep added a commit that referenced this issue Jan 23, 2020
Updates #6789
@bep

This comment has been minimized.

Copy link
Member

@bep bep commented Jan 23, 2020

I have committed a fix that I'm guessing will fix this, but I failed to create a failing test, so it is a little bit guesswork.

@artch

This comment has been minimized.

Copy link
Author

@artch artch commented Jan 24, 2020

Thank you for quick response! I'm sorry I couldn't follow it yesterday.

I don't have any ideas about "what" and "why" as I'm simply using Hugo, not developing it. It was intended to be a user bug report, and not the insightful debug session. I can help with debugging, but only within my limited knowledge.

"Fatal" in that sense means it's a fatal error, i.e. a crash, meaning the process exits and is unable to gracefully handle the error and continue. Nobody died for sure! 🙂

We have a pretty complex web site with two languages and thousands of pages. Many of them are indeed HTML. Its structure looks like this:

                   |  EN  |  RU
+------------------+------+------+
  Pages            | 1414 | 2796
  Paginator pages  |   56 |   74
  Non-page files   |  343 |  391
  Static files     |   21 |   21
  Processed images | 1437 | 1068
  Aliases          |  721 |  880
  Sitemaps         |    2 |    1
  Cleaned          |    0 |    0

Do you have a binary for me to test? I don't have any Go environment to build Hugo on my own.

@artch

This comment has been minimized.

Copy link
Author

@artch artch commented Jan 24, 2020

Sorry, I've just realized there is a new 0.63.1 release already. I checked it, and there is no fatal error leading to a process crash, but instead the process hangs up on Building sites ... line.

@bep bep modified the milestones: v0.63.1, v0.63.2, v0.63.3, v0.64, v0.65 Jan 26, 2020
@bep

This comment has been minimized.

Copy link
Member

@bep bep commented Jan 30, 2020

With the information I have, I'm not able to reproduce or fix this. Maybe others will.

@bep bep added the CantReproduce label Jan 30, 2020
@bep bep modified the milestones: v0.64, v0.65 Jan 30, 2020
@artch

This comment has been minimized.

Copy link
Author

@artch artch commented Jan 30, 2020

Is there some way to enable any debug output to figure out what exactly is hanging up there?

@fmotrifork fmotrifork mentioned this issue Feb 4, 2020
@artch artch changed the title 0.63: "late templates" fails with a nil-pointer 0.64: process hangs up on "Building sites" line Feb 5, 2020
@artch

This comment has been minimized.

Copy link
Author

@artch artch commented Feb 5, 2020

Still reproducible on 0.64 - hugo doesn't render my site and hangs up infinitely.

@moorereason

This comment has been minimized.

Copy link
Contributor

@moorereason moorereason commented Feb 5, 2020

@artch, can you provide access to the site source?

@artch

This comment has been minimized.

Copy link
Author

@artch artch commented Feb 5, 2020

This is complicated, it's intellectual property and I would have to request approval for that. Can I build hugo with some verbose output enabled to help you debug?

@bep bep modified the milestones: v0.65, v0.66 Feb 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.