spf13 / spf13.com

Hugo Based website of Steve Francia
143 stars 87 forks source link

run the website source codes local errors. #1

Open Akagi201 opened 10 years ago

Akagi201 commented 10 years ago
  1. I clone the spf13.com source code.
  2. I run on windows, using the command "hugo server --source=./ --watch"
  3. I get some errors.
$ hugo server --source=./ --watch
panic: runtime error: index out of range

goroutine 1 [running]:
runtime.panic(0x6ec140, 0xb38197)
        /usr/local/go/src/pkg/runtime/panic.c:266 +0xa6
github.com/spf13/hugo/hugolib.Tokenize(0x12026411, 0xa1, 0x1202640d, 0x3)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode
.go:109 +0x60c
github.com/spf13/hugo/hugolib.ShortcodesHandle(0x12026000, 0x4bb, 0x1203a640, 0x
14d328, 0x11e9c8e0, ...)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode
.go:46 +0xfa
github.com/spf13/hugo/hugolib.(*Site).ProcessShortcodes(0x11eeb1c0)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:2
69 +0x80
github.com/spf13/hugo/hugolib.(*Site).Render(0x11eeb1c0, 0x0, 0x0)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:1
72 +0x7a
github.com/spf13/hugo/hugolib.(*Site).Build(0x11eeb1c0, 0x0, 0x0)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:1
09 +0x61
github.com/spf13/hugo/commands.buildSite(0x1825d7, 0x1, 0x1, 0x0, 0x0)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:
149 +0xd7
github.com/spf13/hugo/commands.build(0x182667, 0x1, 0x1)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:
103 +0x1d2
github.com/spf13/hugo/commands.server(0xb35da0, 0x11e52fd0, 0x0, 0x2)
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/server.g
o:48 +0xcf
github.com/spf13/cobra.(*Command).execute(0xb35da0, 0x11e62770, 0x2, 0x2, 0x0, .
..)
        /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:273 +
0xe4
github.com/spf13/cobra.(*Command).findAndExecute(0xb35d20, 0x11e62768, 0x3, 0x3,
 0x0, ...)
        /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:259 +
0x8f
github.com/spf13/cobra.(*Command).Execute(0xb35d20, 0x0, 0x0)
        /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:308 +
0x4e8
github.com/spf13/hugo/commands.Execute()
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:
52 +0x2e
main.main()
        /home/parallels/.gopathBuild/src/github.com/spf13/hugo/main.go:21 +0x1d

goroutine 33 [chan send]:
text/template/parse.lexSpace(0x11e95040, 0x7d48c8)
        /usr/local/go/src/pkg/text/template/parse/lex.go:339 +0xca
text/template/parse.(*lexer).run(0x11e95040)
        /usr/local/go/src/pkg/text/template/parse/lex.go:198 +0x3d
created by text/template/parse.lex
        /usr/local/go/src/pkg/text/template/parse/lex.go:191 +0xef
spf13 commented 10 years ago

Please use hugo HEAD for this. I often use spf13.com as a sandbox to implement new Hugo features. 

Best, Steve

--  Steve Francia http://stevefrancia.com http://spf13.com http://twitter.com/spf13

On January 20, 2014 at 4:16:09 AM, Bob Liu (notifications@github.com) wrote:

I clone the spf13.com source code. I run on windows, using the command "hugo server --source=./ --watch" I get some errors. $ hugo server --source=./ --watch panic: runtime error: index out of range

goroutine 1 [running]: runtime.panic(0x6ec140, 0xb38197) /usr/local/go/src/pkg/runtime/panic.c:266 +0xa6 github.com/spf13/hugo/hugolib.Tokenize(0x12026411, 0xa1, 0x1202640d, 0x3) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode .go:109 +0x60c github.com/spf13/hugo/hugolib.ShortcodesHandle(0x12026000, 0x4bb, 0x1203a640, 0x 14d328, 0x11e9c8e0, ...) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode .go:46 +0xfa github.com/spf13/hugo/hugolib.(_Site).ProcessShortcodes(0x11eeb1c0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:2 69 +0x80 github.com/spf13/hugo/hugolib.(_Site).Render(0x11eeb1c0, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:1 72 +0x7a github.com/spf13/hugo/hugolib.(_Site).Build(0x11eeb1c0, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:1 09 +0x61 github.com/spf13/hugo/commands.buildSite(0x1825d7, 0x1, 0x1, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go: 149 +0xd7 github.com/spf13/hugo/commands.build(0x182667, 0x1, 0x1) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go: 103 +0x1d2 github.com/spf13/hugo/commands.server(0xb35da0, 0x11e52fd0, 0x0, 0x2) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/server.g o:48 +0xcf github.com/spf13/cobra.(_Command).execute(0xb35da0, 0x11e62770, 0x2, 0x2, 0x0, . ..) /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:273 + 0xe4 github.com/spf13/cobra.(_Command).findAndExecute(0xb35d20, 0x11e62768, 0x3, 0x3, 0x0, ...) /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:259 + 0x8f github.com/spf13/cobra.(_Command).Execute(0xb35d20, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:308 + 0x4e8 github.com/spf13/hugo/commands.Execute() /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go: 52 +0x2e main.main() /home/parallels/.gopathBuild/src/github.com/spf13/hugo/main.go:21 +0x1d

goroutine 33 [chan send]: text/template/parse.lexSpace(0x11e95040, 0x7d48c8) /usr/local/go/src/pkg/text/template/parse/lex.go:339 +0xca text/template/parse.(*lexer).run(0x11e95040) /usr/local/go/src/pkg/text/template/parse/lex.go:198 +0x3d created by text/template/parse.lex /usr/local/go/src/pkg/text/template/parse/lex.go:191 +0xef

— Reply to this email directly or view it on GitHub.

luckypoem commented 10 years ago

hi. i also met the similar error.what does "hugo HEAD " mean?? how to fix the error?

as3:~/mygo/src/github.com/spf13/hugo/examples/spf13.com# ls config.json config.yaml layouts static
config.toml content README.md as3:~/mygo/src/github.com/spf13/hugo/examples/spf13.com# hugo --source=. --destination=export --config=config.yaml panic: runtime error: index out of range goroutine 1 [running]: runtime.panic(0x832c460, 0x8763ef7) /usr/local/go/src/pkg/runtime/panic.c:266 +0xac github.com/spf13/hugo/hugolib.Tokenize(0x18aac911, 0xa1, 0x18aac90d, 0x3) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode.go:109 +0x60d github.com/spf13/hugo/hugolib.ShortcodesHandle(0x18aac500, 0x4bb, 0x18af5280, 0xb775ae08, 0x18a82440, ...) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode.go:46 +0xfb github.com/spf13/hugo/hugolib.(_Site).ProcessShortcodes(0x18a3e540) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:269 +0x81 github.com/spf13/hugo/hugolib.(_Site).Render(0x18a3e540, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:172 +0x7b github.com/spf13/hugo/hugolib.(_Site).Build(0x18a3e540, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:109 +0x62 github.com/spf13/hugo/commands.buildSite(0xb766fe7b, 0x1, 0x1, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:149 +0xd8 github.com/spf13/hugo/commands.build(0x0, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:103 +0x1d3 github.com/spf13/hugo/commands.func·003(0x8761be0, 0x18ab0e60, 0x0, 0x3) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:41 +0x31 github.com/spf13/cobra.(_Command).Execute(0x8761be0, 0xb775a740, 0x18ab7f70) /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:321 +0x495 github.com/spf13/hugo/commands.Execute() /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:52 +0x2f main.main() /home/parallels/.gopathBuild/src/github.com/spf13/hugo/main.go:21 +0x1e goroutine 33 [chan send]: text/template/parse.lexSpace(0x18ab8e00, 0x840e2e0) /usr/local/go/src/pkg/text/template/parse/lex.go:339 +0xcb text/template/parse.(*lexer).run(0x18ab8e00) /usr/local/go/src/pkg/text/template/parse/lex.go:198 +0x3e created by text/template/parse.lex /usr/local/go/src/pkg/text/template/parse/lex.go:191 +0xf0 as3:~/mygo/src/github.com/spf13/hugo/examples/spf13.com#

spf13 commented 10 years ago

You’re using an older build of hugo. Please upgrade to v0.10  https://github.com/spf13/hugo/releases

Best, Steve

--  Steve Francia http://stevefrancia.com http://spf13.com http://twitter.com/spf13

From: luckypoem notifications@github.com Reply: spf13/spf13.com reply@reply.github.com Date: March 11, 2014 at 9:10:29 AM To: spf13/spf13.com spf13.com@noreply.github.com Cc: Steve Francia steve.francia@gmail.com Subject:  Re: [spf13.com] run the website source codes local errors. (#1)

hi. i also met the similar error.what does "hugo HEAD " mean?? how to fix the error?

as3:~/mygo/src/github.com/spf13/hugo/examples/spf13.com# ls config.json config.yaml layouts static

config.toml content README.md as3:~/mygo/src/github.com/spf13/hugo/examples/spf13.com# hugo --source=. --destination=export --config=config.yaml panic: runtime error: index out of range goroutine 1 [running]: runtime.panic(0x832c460, 0x8763ef7) /usr/local/go/src/pkg/runtime/panic.c:266 +0xac github.com/spf13/hugo/hugolib.Tokenize(0x18aac911, 0xa1, 0x18aac90d, 0x3) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode.go:109 +0x60d github.com/spf13/hugo/hugolib.ShortcodesHandle(0x18aac500, 0x4bb, 0x18af5280, 0xb775ae08, 0x18a82440, ...) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/shortcode.go:46 +0xfb github.com/spf13/hugo/hugolib.(Site).ProcessShortcodes(0x18a3e540) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:269 +0x81 github.com/spf13/hugo/hugolib.(Site).Render(0x18a3e540, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:172 +0x7b github.com/spf13/hugo/hugolib.(Site).Build(0x18a3e540, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/hugolib/site.go:109 +0x62 github.com/spf13/hugo/commands.buildSite(0xb766fe7b, 0x1, 0x1, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:149 +0xd8 github.com/spf13/hugo/commands.build(0x0, 0x0, 0x0) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:103 +0x1d3 github.com/spf13/hugo/commands.func·003(0x8761be0, 0x18ab0e60, 0x0, 0x3) /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:41 +0x31 github.com/spf13/cobra.(Command).Execute(0x8761be0, 0xb775a740, 0x18ab7f70) /home/parallels/.gopathBuild/src/github.com/spf13/cobra/command.go:321 +0x495 github.com/spf13/hugo/commands.Execute() /home/parallels/.gopathBuild/src/github.com/spf13/hugo/commands/hugo.go:52 +0x2f main.main() /home/parallels/.gopathBuild/src/github.com/spf13/hugo/main.go:21 +0x1e goroutine 33 [chan send]: text/template/parse.lexSpace(0x18ab8e00, 0x840e2e0) /usr/local/go/src/pkg/text/template/parse/lex.go:339 +0xcb text/template/parse.(*lexer).run(0x18ab8e00) /usr/local/go/src/pkg/text/template/parse/lex.go:198 +0x3e created by text/template/parse.lex /usr/local/go/src/pkg/text/template/parse/lex.go:191 +0xf0 as3:~/mygo/src/github.com/spf13/hugo/examples/spf13.com#

— Reply to this email directly or view it on GitHub.

luckypoem commented 10 years ago

hi. i ever saw some demo site using ur app:hugo,i forgot the page's url which display the demo sites,can u tell me the page's url?