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

panic: runtime error: index out of range #13

Closed
Maimer opened this issue Apr 8, 2015 · 1 comment
Closed

panic: runtime error: index out of range #13

Maimer opened this issue Apr 8, 2015 · 1 comment

Comments

@Maimer
Copy link
Contributor

Maimer commented Apr 8, 2015

./rsc --x1 ':has(.val:rel("parent")).href' cm15 show "$instance_href"
panic: runtime error: index out of range

goroutine 1 [running]:
github.com/rightscale/go-jsonselect.func·030(0x209746960, 0x0)
/home/travis/gopath/src/github.com/rightscale/rsc/Godeps/_workspace/src/github.com/rightscale/go-jsonselect/jsonselect.go:436 +0x951
github.com/rightscale/go-jsonselect.(_Parser).matchNodes(0x209776c80, 0x2095dd800, 0x1, 0xa, 0x20977d600, 0x3b, 0x40, 0x0, 0x0, 0x0, ...)
/home/travis/gopath/src/github.com/rightscale/rsc/Godeps/_workspace/src/github.com/rightscale/go-jsonselect/jsonselect.go:227 +0x415
github.com/rightscale/go-jsonselect.(_Parser).selectorProduction(0x209776c80, 0x209777430, 0x1, 0x2, 0x20977d600, 0x3b, 0x40, 0x1, 0x0, 0x0, ...)
/home/travis/gopath/src/github.com/rightscale/rsc/Godeps/_workspace/src/github.com/rightscale/go-jsonselect/jsonselect.go:139 +0x1270
github.com/rightscale/go-jsonselect.(_Parser).evaluateSelector(0x209776c80, 0x7fff5fbff913, 0x1d, 0x0, 0x0, 0x0, 0x0, 0x0)
/home/travis/gopath/src/github.com/rightscale/rsc/Godeps/_workspace/src/github.com/rightscale/go-jsonselect/jsonselect.go:41 +0x168
github.com/rightscale/go-jsonselect.(_Parser).GetValues(0x209776c80, 0x7fff5fbff913, 0x1d, 0x0, 0x0, 0x0, 0x0, 0x0)
/home/travis/gopath/src/github.com/rightscale/rsc/Godeps/_workspace/src/github.com/rightscale/go-jsonselect/jsonselect.go:68 +0x89
main.(_Displayer).ApplyExtract(0x209735aa0, 0x7fff5fbff913, 0x1d, 0x20972f501, 0x0, 0x0)
/home/travis/gopath/src/github.com/rightscale/rsc/displayer.go:73 +0x214
main.(_Displayer).ApplySingleExtract(0x209735aa0, 0x7fff5fbff913, 0x1d, 0x0, 0x0)
/home/travis/gopath/src/github.com/rightscale/rsc/displayer.go:40 +0x6d
main.main()
/home/travis/gopath/src/github.com/rightscale/rsc/main.go:61 +0x354

goroutine 13 [runnable]:
net/http.(*persistConn).readLoop(0x209399ef0)
/home/travis/.gimme/versions/go1.4.linux.amd64/src/net/http/transport.go:928 +0x9ce

raphael pushed a commit that referenced this issue Apr 27, 2015
@raphael
Copy link

raphael commented Apr 27, 2015

This is fixed in master. Also note that what you were after is probably:

rsc --x1 ':has(.rel:val("parent")).href' cm15 show "$instance_href"

@raphael raphael closed this as completed Apr 27, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants