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: invalid memory address or nil pointer dereference" when quiet() is part of join assignment #5098

Open
philrz opened this issue Apr 4, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@philrz
Copy link
Contributor

philrz commented Apr 4, 2024

Repro is with GA Zed tagged v1.15.0.

To repro, use attached Test data and conn.zng.gz and http.zng.gz with the following Zed script add-geo-to-http.zed:

file http.zng.gz
| inner join (
  file conn.zng.gz
  | head 100
  | _path=="conn"
) on uid=uid geo:=quiet(geo)

The panic:

$ zq -version
Version: v1.15.0

$ zq -I add-geo-to-http.zed 
panic: runtime error: invalid memory address or nil pointer dereference
goroutine 1 [running]:
runtime/debug.Stack()
	/usr/local/opt/go@1.21/libexec/src/runtime/debug/stack.go:24 +0x5e
github.com/brimdata/zed/runtime/sam/op.(*Catcher).Pull.func1()
	/Users/phil/work/zed/runtime/sam/op/catcher.go:25 +0x3d
panic({0x24052c0?, 0x3652d70?})
	/usr/local/opt/go@1.21/libexec/src/runtime/panic.go:914 +0x21f
github.com/brimdata/zed/runtime/sam/op/join.(*Op).buildType(0xc00057c820, 0xc0005ec180, 0x0)
	/Users/phil/work/zed/runtime/sam/op/join/join.go:226 +0x32
github.com/brimdata/zed/runtime/sam/op/join.(*Op).combinedType(0xc00057c820, 0xc0005ec180, 0x0)
	/Users/phil/work/zed/runtime/sam/op/join/join.go:242 +0x7f
github.com/brimdata/zed/runtime/sam/op/join.(*Op).splice(0xc00057c780?, {{0x28c64b0?, 0xc0005ec180?}, 0xc000e92140?, 0xc00049d740?}, {{0x28c6528?, 0xc00014c540?}, 0x3596538?, 0xc000154780?})
	/Users/phil/work/zed/runtime/sam/op/join/join.go:253 +0x1ab
github.com/brimdata/zed/runtime/sam/op/join.(*Op).Pull(0xc00057c820, 0x5?)
	/Users/phil/work/zed/runtime/sam/op/join/join.go:131 +0x538
github.com/brimdata/zed/runtime/sam/op.(*Single).Pull(0xc00014c5e8, 0x20)
	/Users/phil/work/zed/runtime/sam/op/mux.go:134 +0x2b
github.com/brimdata/zed/runtime/sam/op.(*Catcher).Pull(0x3cbf5b8?, 0x0?)
	/Users/phil/work/zed/runtime/sam/op/catcher.go:28 +0x62
github.com/brimdata/zed/runtime/exec.(*Query).Pull(0x4ab82f58?, 0xd8?)
	/Users/phil/work/zed/runtime/exec/query.go:59 +0x3e
github.com/brimdata/zed/zbuf.CopyPuller({0x4ab82f58, 0xc0005b9548}, {0x28c0220, 0xc00011b920})
	/Users/phil/work/zed/zbuf/batch.go:162 +0x4d
github.com/brimdata/zed/cli/zq.(*Command).Run(0xc0004c2a80, {0xc000040740, 0x0, 0x0})
	/Users/phil/work/zed/cli/zq/command.go:162 +0x79e
github.com/brimdata/zed/pkg/charm.path.run({0xc0006a8300?, 0x1, 0x1}, {0xc000040740?, 0x0, 0x0?})
	/Users/phil/work/zed/pkg/charm/path.go:11 +0x79
github.com/brimdata/zed/pkg/charm.(*Spec).ExecRoot(0x100874b?, {0xc000040730, 0x2, 0x2})
	/Users/phil/work/zed/pkg/charm/charm.go:63 +0x3f
main.main()
	/Users/phil/work/zed/cmd/zq/main.go:11 +0x5b

I originally wrote the Zed without the quiet() wrapper and caused the crash once I added it.

@philrz philrz added the bug Something isn't working label Apr 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant