Skip to content

Instantly share code, notes, and snippets.

@brunoamaral
Created April 12, 2019 09:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brunoamaral/4686ca9be417ed97b9a26077e70d2f82 to your computer and use it in GitHub Desktop.
Save brunoamaral/4686ca9be417ed97b9a26077e70d2f82 to your computer and use it in GitHub Desktop.
@DeLorean:~/Digital-Insanity$ hugo --cleanDestinationDir
Building sites … fatal error: runtime: out of memory
runtime stack:
runtime.throw(0x12202bd, 0x16)
/usr/local/go/src/runtime/panic.go:617 +0x72
runtime.sysMap(0xc04c000000, 0x4000000, 0x1eb5cd8)
/usr/local/go/src/runtime/mem_linux.go:170 +0xc7
runtime.(*mheap).sysAlloc(0x1e8ef80, 0x484000, 0x1e8ef90, 0x242)
/usr/local/go/src/runtime/malloc.go:633 +0x1cd
runtime.(*mheap).grow(0x1e8ef80, 0x242, 0x0)
/usr/local/go/src/runtime/mheap.go:1232 +0x42
runtime.(*mheap).allocSpanLocked(0x1e8ef80, 0x242, 0x1eb5ce8, 0x1e405a0)
/usr/local/go/src/runtime/mheap.go:1150 +0x3a7
runtime.(*mheap).alloc_m(0x1e8ef80, 0x242, 0x101, 0xc000348300)
/usr/local/go/src/runtime/mheap.go:977 +0xc2
runtime.(*mheap).alloc.func1()
/usr/local/go/src/runtime/mheap.go:1048 +0x4c
runtime.(*mheap).alloc(0x1e8ef80, 0x242, 0x7f2f7e010101, 0x4ae3b0)
/usr/local/go/src/runtime/mheap.go:1047 +0x8a
runtime.largeAlloc(0x484000, 0x4e0101, 0xc031e6a000)
/usr/local/go/src/runtime/malloc.go:1055 +0x99
runtime.mallocgc.func1()
/usr/local/go/src/runtime/malloc.go:950 +0x46
runtime.systemstack(0x0)
/usr/local/go/src/runtime/asm_amd64.s:351 +0x66
runtime.mstart()
/usr/local/go/src/runtime/proc.go:1153
goroutine 459 [running]:
runtime.systemstack_switch()
/usr/local/go/src/runtime/asm_amd64.s:311 fp=0xc014e1b9d0 sp=0xc014e1b9c8 pc=0x4e24c0
runtime.mallocgc(0x484000, 0x10d26a0, 0x1, 0xc014e1bad0)
/usr/local/go/src/runtime/malloc.go:949 +0x872 fp=0xc014e1ba70 sp=0xc014e1b9d0 pc=0x493d02
runtime.makeslice(0x10d26a0, 0x4840, 0x4840, 0x80)
/usr/local/go/src/runtime/slice.go:49 +0x6c fp=0xc014e1baa0 sp=0xc014e1ba70 pc=0x4cb5fc
image/jpeg.(*decoder).processSOS(0xc020744a00, 0x6, 0x2, 0x80)
/usr/local/go/src/image/jpeg/scan.go:156 +0x5cd fp=0xc014e1bcd0 sp=0xc014e1baa0 pc=0xc7257d
image/jpeg.(*decoder).decode(0xc020744a00, 0x1424320, 0xc0257b4cc0, 0x491800, 0x10e5940, 0x1191fe0, 0x128f100, 0x1424320)
/usr/local/go/src/image/jpeg/reader.go:630 +0x2f8 fp=0xc014e1bd20 sp=0xc014e1bcd0 pc=0xc707c8
image/jpeg.Decode(0x1424320, 0xc0257b4cc0, 0xc0257b4cc0, 0x1424320, 0xc0257b4cc0, 0x2)
/usr/local/go/src/image/jpeg/reader.go:779 +0x54 fp=0xc014e1bd70 sp=0xc014e1bd20 pc=0xc71784
image.Decode(0x7f2f8430dff8, 0xc01cd6d960, 0xc01cd6d960, 0x7f2f8430dff8, 0xc01cd6d960, 0xc01f7fb700, 0x1088e20, 0xc01f7fb710)
/usr/local/go/src/image/format.go:93 +0xff fp=0xc014e1be68 sp=0xc014e1bd70 pc=0xc603ff
github.com/gohugoio/hugo/resources.(*Image).decodeSource(0xc00aa63b30, 0x0, 0x0, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/resources/image.go:458 +0xbe fp=0xc014e1bec8 sp=0xc014e1be68 pc=0xcc4abe
github.com/gohugoio/hugo/resources.(*Image).doWithImageConfig.func1(0x0, 0x0, 0x0, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/resources/image.go:258 +0x2a2 fp=0xc014e1c120 sp=0xc014e1bec8 pc=0xcd0892
github.com/gohugoio/hugo/resources.(*imageCache).getOrCreate.func2(0xc00b404f01, 0xb8, 0x7f2f850c30d8, 0xc01cd6d900, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/resources/image_cache.go:113 +0x5d fp=0xc014e1c270 sp=0xc014e1c120 pc=0xcd16fd
github.com/gohugoio/hugo/cache/filecache.(*Cache).ReadOrCreate(0xc00027a4e0, 0xc00b404f01, 0xb8, 0xc001fdf800, 0xc018240b40, 0xc00b404f01, 0xb8, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/cache/filecache/filecache.go:144 +0x28c fp=0xc014e1c2d0 sp=0xc014e1c270 pc=0xc5929c
github.com/gohugoio/hugo/resources.(*imageCache).getOrCreate(0xc00239df80, 0xc00aa63b30, 0x11d2d8a, 0x4, 0x5a, 0x0, 0x1c2, 0x96, 0x4008000000000000, 0x128e200, ...)
/go/src/github.com/gohugoio/hugo/resources/image_cache.go:142 +0x3aa fp=0xc014e1c3f0 sp=0xc014e1c2d0 pc=0xcc634a
github.com/gohugoio/hugo/resources.(*Image).doWithImageConfig(0xc00aa63b30, 0x11d2d8a, 0x4, 0xc0004ac2ad, 0x7, 0x128e510, 0xc0092c9500, 0xc014e1c578, 0x49b3a5)
/go/src/github.com/gohugoio/hugo/resources/image.go:245 +0x1f4 fp=0xc014e1c508 sp=0xc014e1c3f0 pc=0xcc38d4
github.com/gohugoio/hugo/resources.(*Image).Fill(0xc00aa63b30, 0xc0004ac2ad, 0x7, 0x0, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/resources/image.go:176 +0x60 fp=0xc014e1c560 sp=0xc014e1c508 pc=0xcc3570
runtime.call64(0xc010358d80, 0xc01a6d0590, 0xc012ad9260, 0x1800000030)
/usr/local/go/src/runtime/asm_amd64.s:520 +0x3b fp=0xc014e1c5b0 sp=0xc014e1c560 pc=0x4e28fb
reflect.Value.call(0x11b8f20, 0xc00aa63b30, 0xa13, 0x11d21ca, 0x4, 0xc01cd6d880, 0x1, 0x1, 0xc00016ee00, 0xc014e1c910, ...)
/usr/local/go/src/reflect/value.go:447 +0x461 fp=0xc014e1c7d0 sp=0xc014e1c5b0 pc=0x542c81
reflect.Value.Call(0x11b8f20, 0xc00aa63b30, 0xa13, 0xc01cd6d880, 0x1, 0x1, 0x4cb5fc, 0x20, 0x11c3f80)
/usr/local/go/src/reflect/value.go:308 +0xa4 fp=0xc014e1c838 sp=0xc014e1c7d0 pc=0x542704
text/template.safeCall(0x11b8f20, 0xc00aa63b30, 0xa13, 0xc01cd6d880, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, ...)
/usr/local/go/src/text/template/funcs.go:293 +0xb6 fp=0xc014e1c8a0 sp=0xc014e1c838 pc=0x6275d6
text/template.(*state).evalCall(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0x11b8f20, 0xc00aa63b30, 0xa13, 0x143e9a0, 0xc0007fd470, 0xc0004ac2a7, ...)
/usr/local/go/src/text/template/exec.go:703 +0x68c fp=0xc014e1c9f0 sp=0xc014e1c8a0 pc=0x620cfc
text/template.(*state).evalField(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0xc0004ac2a7, 0x4, 0x143e9a0, 0xc0007fd470, 0xc0007fa8a0, 0x2, ...)
/usr/local/go/src/text/template/exec.go:593 +0xd61 fp=0xc014e1cbc0 sp=0xc014e1c9f0 pc=0x620551
text/template.(*state).evalFieldChain(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0x1127300, 0xc012ad91e8, 0x94, 0x143e9a0, 0xc0007fd470, 0xc000800320, ...)
/usr/local/go/src/text/template/exec.go:554 +0x220 fp=0xc014e1cc78 sp=0xc014e1cbc0 pc=0x61f500
text/template.(*state).evalFieldNode(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0xc0007fd470, 0xc0007fa8a0, 0x2, 0x2, 0x10d8940, 0x1eb3fc8, ...)
/usr/local/go/src/text/template/exec.go:518 +0x114 fp=0xc014e1cd30 sp=0xc014e1cc78 pc=0x61ec64
text/template.(*state).evalCommand(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0xc0007fd440, 0x10d8940, 0x1eb3fc8, 0x99, 0xc014e1cf10, 0x61e3cc, ...)
/usr/local/go/src/text/template/exec.go:456 +0x7a8 fp=0xc014e1ce00 sp=0xc014e1cd30 pc=0x61e508
text/template.(*state).evalPipeline(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0xc0007fe480, 0x61da55, 0x1127300, 0x8)
/usr/local/go/src/text/template/exec.go:430 +0x11c fp=0xc014e1cef0 sp=0xc014e1ce00 pc=0x61d93c
text/template.(*state).walk(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0x143e820, 0xc0007fd4a0)
/usr/local/go/src/text/template/exec.go:254 +0x49c fp=0xc014e1cf80 sp=0xc014e1cef0 pc=0x61c32c
text/template.(*state).walk(0xc014e1d688, 0x1127300, 0xc012ad91e8, 0x94, 0x143ea60, 0xc0007fd3e0)
/usr/local/go/src/text/template/exec.go:262 +0x143 fp=0xc014e1d010 sp=0xc014e1cf80 pc=0x61bfd3
text/template.(*state).walkIfOrWith(0xc014e1d688, 0x13, 0x11bc6c0, 0xc0118e8cd0, 0x194, 0xc0007fe420, 0xc0007fd3e0, 0xc0007fd590)
/usr/local/go/src/text/template/exec.go:290 +0x15d fp=0xc014e1d0a8 sp=0xc014e1d010 pc=0x61c56d
text/template.(*state).walk(0xc014e1d688, 0x11bc6c0, 0xc0118e8cd0, 0x194, 0x143eca0, 0xc0007f3a00)
/usr/local/go/src/text/template/exec.go:273 +0x2ba fp=0xc014e1d138 sp=0xc014e1d0a8 pc=0x61c14a
text/template.(*state).walk(0xc014e1d688, 0x11bc6c0, 0xc0118e8cd0, 0x194, 0x143ea60, 0xc0007fc510)
/usr/local/go/src/text/template/exec.go:262 +0x143 fp=0xc014e1d1c8 sp=0xc014e1d138 pc=0x61bfd3
text/template.(*state).walkIfOrWith(0xc014e1d688, 0xa, 0x11bc6c0, 0xc0118e8cd0, 0x194, 0xc0007f5e60, 0xc0007fc510, 0x0)
/usr/local/go/src/text/template/exec.go:292 +0x1c4 fp=0xc014e1d260 sp=0xc014e1d1c8 pc=0x61c5d4
text/template.(*state).walk(0xc014e1d688, 0x11bc6c0, 0xc0118e8cd0, 0x194, 0x143ea20, 0xc0007f3a40)
/usr/local/go/src/text/template/exec.go:259 +0x328 fp=0xc014e1d2f0 sp=0xc014e1d260 pc=0x61c1b8
text/template.(*state).walk(0xc014e1d688, 0x11bc6c0, 0xc0118e8cd0, 0x194, 0x143ea60, 0xc0007fc420)
/usr/local/go/src/text/template/exec.go:262 +0x143 fp=0xc014e1d380 sp=0xc014e1d2f0 pc=0x61bfd3
text/template.(*state).walkRange.func1(0x1087ea0, 0xc0131c2b50, 0x82, 0x11bc6c0, 0xc0118e8cd0, 0x194)
/usr/local/go/src/text/template/exec.go:349 +0x125 fp=0xc014e1d3d0 sp=0xc014e1d380 pc=0x62d625
text/template.(*state).walkRange(0xc014e1d688, 0x11cdc60, 0xc005ccff80, 0x16, 0xc0007f3a80)
/usr/local/go/src/text/template/exec.go:358 +0x506 fp=0xc014e1d500 sp=0xc014e1d3d0 pc=0x61d166
text/template.(*state).walk(0xc001fc7688, 0x11cdc60, 0xc005ccff80, 0x16, 0x143eb60, 0xc0007f3a80)
/usr/local/go/src/text/template/exec.go:265 +0x43e fp=0xc014e1d590 sp=0xc014e1d500 pc=0x61c2ce
text/template.(*state).walk(0xc014e1d688, 0x11cdc60, 0xc005ccff80, 0x16, 0x143ea60, 0xc0007fc2a0)
/usr/local/go/src/text/template/exec.go:262 +0x143 fp=0xc014e1d620 sp=0xc014e1d590 pc=0x61bfd3
text/template.(*Template).execute(0xc00262b800, 0x1424380, 0xc027da98f0, 0x11cdc60, 0xc005ccff80, 0x0, 0x0)
/usr/local/go/src/text/template/exec.go:217 +0x1e8 fp=0xc014e1d6e0 sp=0xc014e1d620 pc=0x61ba18
text/template.(*Template).Execute(0xc00262b800, 0x1424380, 0xc027da98f0, 0x11cdc60, 0xc005ccff80, 0x142e0e0, 0xc01dcd10e0)
/usr/local/go/src/text/template/exec.go:200 +0x53 fp=0xc014e1d728 sp=0xc014e1d6e0 pc=0x61b803
github.com/gohugoio/hugo/tpl.(*TemplateAdapter).Execute(0xc01dcd10e0, 0x1424380, 0xc027da98f0, 0x11cdc60, 0xc005ccff80, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/tpl/template.go:163 +0xaf fp=0xc014e1d788 sp=0xc014e1d728 pc=0xc56aef
github.com/gohugoio/hugo/hugolib.(*Site).renderForLayouts(0xc00005ae00, 0x11d2f0e, 0x4, 0x11d23da, 0x4, 0x11cdc60, 0xc005ccff80, 0x1424380, 0xc027da98f0, 0xc021444c00, ...)
/go/src/github.com/gohugoio/hugo/hugolib/site.go:1800 +0xb8 fp=0xc014e1d830 sp=0xc014e1d788 pc=0xdf9f78
github.com/gohugoio/hugo/hugolib.(*Site).renderAndWritePage(0xc00005ae00, 0xc0023b6290, 0xc001fc7d58, 0x1e, 0xc00bfac160, 0xe, 0xc005ccff80, 0xc021444c00, 0x24, 0x40, ...)
/go/src/github.com/gohugoio/hugo/hugolib/site.go:1716 +0x1a6 fp=0xc014e1dcd8 sp=0xc014e1d830 pc=0xdf9886
github.com/gohugoio/hugo/hugolib.pageRenderer(0xc00722a680, 0xc00005ae00, 0xc021e1be00, 0xc016f2ae40, 0xc00dc75730)
/go/src/github.com/gohugoio/hugo/hugolib/site_render.go:153 +0x545 fp=0xc014e1dfb8 sp=0xc014e1dcd8 pc=0xdfcce5
runtime.goexit()
/usr/local/go/src/runtime/asm_amd64.s:1337 +0x1 fp=0xc014e1dfc0 sp=0xc014e1dfb8 pc=0x4e4591
created by github.com/gohugoio/hugo/hugolib.(*Site).renderPages
/go/src/github.com/gohugoio/hugo/hugolib/site_render.go:72 +0x160
goroutine 1 [semacquire]:
sync.runtime_Semacquire(0xc00dc75738)
/usr/local/go/src/runtime/sema.go:56 +0x39
sync.(*WaitGroup).Wait(0xc00dc75730)
/usr/local/go/src/sync/waitgroup.go:130 +0x65
github.com/gohugoio/hugo/hugolib.(*Site).renderPages(0xc00005ae00, 0xc00722a680, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/hugolib/site_render.go:96 +0x285
github.com/gohugoio/hugo/hugolib.(*Site).render(0xc00005ae00, 0xc00722a680, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/hugolib/site.go:1161 +0x55
github.com/gohugoio/hugo/hugolib.(*HugoSites).render(0xc00052be30, 0xc00393eec0, 0xc001d7b948, 0x20)
/go/src/github.com/gohugoio/hugo/hugolib/hugo_sites_build.go:302 +0x3ee
github.com/gohugoio/hugo/hugolib.(*HugoSites).Build.func4()
/go/src/github.com/gohugoio/hugo/hugolib/hugo_sites_build.go:121 +0x3c
runtime/trace.WithRegion(0x143b8a0, 0xc00810b290, 0x11da529, 0x6, 0xc001d7ba68)
/usr/local/go/src/runtime/trace/annotation.go:137 +0xe9
github.com/gohugoio/hugo/hugolib.(*HugoSites).Build(0xc00052be30, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
/go/src/github.com/gohugoio/hugo/hugolib/hugo_sites_build.go:123 +0x66b
github.com/gohugoio/hugo/commands.(*commandeer).buildSites(...)
/go/src/github.com/gohugoio/hugo/commands/hugo.go:763
github.com/gohugoio/hugo/commands.(*commandeer).fullBuild.func3(0x0, 0x0)
/go/src/github.com/gohugoio/hugo/commands/hugo.go:313 +0x79
github.com/gohugoio/hugo/commands.(*commandeer).fullBuild(0xc0003fa240, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/commands/hugo.go:325 +0x165
github.com/gohugoio/hugo/commands.(*commandeer).build(0xc0003fa240, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/commands/hugo.go:474 +0xfd
github.com/gohugoio/hugo/commands.(*commandsBuilder).newHugoCmd.func1(0xc00011b900, 0xc0004facf0, 0x0, 0x1, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/commands/commands.go:160 +0xc3
github.com/spf13/cobra.(*Command).execute(0xc00011b900, 0xc00000e070, 0x1, 0x1, 0xc00011b900, 0xc00000e070)
/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:762 +0x465
github.com/spf13/cobra.(*Command).ExecuteC(0xc00011b900, 0xc0004fabf0, 0xc00008fa10, 0xc0004fa870)
/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:852 +0x2ec
github.com/gohugoio/hugo/commands.Execute(0xc00000e070, 0x1, 0x1, 0x48d56f, 0xc000084058, 0x0, 0x0)
/go/src/github.com/gohugoio/hugo/commands/hugo.go:91 +0xbb
main.main()
/go/src/github.com/gohugoio/hugo/main.go:23 +0x6a
goroutine 9 [syscall, 3 minutes]:
os/signal.signal_recv(0x0)
/usr/local/go/src/runtime/sigqueue.go:139 +0x9c
os/signal.loop()
/usr/local/go/src/os/signal/signal_unix.go:23 +0x22
created by os/signal.init.0
/usr/local/go/src/os/signal/signal_unix.go:29 +0x41
goroutine 113 [chan receive, 3 minutes]:
github.com/gohugoio/hugo/hugolib.(*HugoSites).Build.func1(0xc00052be30, 0xc009bc12c0, 0xc015c48ba0)
/go/src/github.com/gohugoio/hugo/hugolib/hugo_sites_build.go:43 +0x7c
created by github.com/gohugoio/hugo/hugolib.(*HugoSites).Build
/go/src/github.com/gohugoio/hugo/hugolib/hugo_sites_build.go:40 +0x1af
goroutine 458 [chan receive]:
github.com/gohugoio/hugo/hugolib.(*Site).errorCollator(0xc00005ae00, 0xc016f2ae40, 0xc016f2aea0)
/go/src/github.com/gohugoio/hugo/hugolib/site.go:1642 +0x72
created by github.com/gohugoio/hugo/hugolib.(*Site).renderPages
/go/src/github.com/gohugoio/hugo/hugolib/site_render.go:66 +0xdb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment