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

Crash when attempting to output top-level value as Zeek TSV #4424

Closed
philrz opened this issue Mar 4, 2023 · 1 comment
Closed

Crash when attempting to output top-level value as Zeek TSV #4424

philrz opened this issue Mar 4, 2023 · 1 comment
Labels
bug Something isn't working duplicate This issue or pull request already exists

Comments

@philrz
Copy link
Contributor

philrz commented Mar 4, 2023

Repro is where this issue first surfaced in Zed commit 524f500, which is associated with the changes in #3300. It's still with us at current tip of main, commit 81a9273. We became aware of this issue because the nightly perf-compare automation attempts a count() with output in Zeek TSV format, so the recent changes in #4420 made that script crash where it hadn't before.

$ zed -version
Version: v0.33.0-5-g524f5009

$ echo '"hello"' | zq -z -
"hello"

$ echo '"hello"' | zq -f zeek -
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x11dc4ff]

goroutine 1 [running]:
github.com/brimdata/zed.(*Value).Columns(...)
	/Users/phil/work/zed/recordval.go:137
github.com/brimdata/zed/expr.(*Flattener).Flatten(0xc000370ef0, 0xc0003f4000)
	/Users/phil/work/zed/expr/flattener.go:73 +0x7f
github.com/brimdata/zed/zio/zeekio.(*Writer).Write(0xc000342a50, 0xc00004a0a0?)
	/Users/phil/work/zed/zio/zeekio/writer.go:44 +0x3d
github.com/brimdata/zed/zbuf.WriteBatch({0x2a96a318, 0xc000342a50}, {0x18de710?, 0xc00031a7b0?})
	/Users/phil/work/zed/zbuf/batch.go:37 +0x77
github.com/brimdata/zed/driver.(*CLI).Write(0xc00019f9e8?, 0xc00019f910?, {0x18de710?, 0xc00031a7b0?})
	/Users/phil/work/zed/driver/driver.go:207 +0x99
github.com/brimdata/zed/driver.run(0xc000373d10, {0x18df340, 0xc000373cb0}, 0xc00033f500, 0x0)
	/Users/phil/work/zed/driver/driver.go:151 +0x4be
github.com/brimdata/zed/driver.RunWithFileSystem({0x18df6f8?, 0xc000037b40?}, {0x18df340, 0xc000373cb0}, {0x18d71c0, 0xc000372ed0}, 0x1?, {0xc000370ec0, 0x1, 0x1}, ...)
	/Users/phil/work/zed/driver/driver.go:58 +0xe5
github.com/brimdata/zed/cmd/zed/query.(*Command).Run(0xc000156c60, {0xc0000372f0, 0x1, 0x1})
	/Users/phil/work/zed/cmd/zed/query/command.go:164 +0x74c
github.com/brimdata/zed/pkg/charm.path.run({0xc0002983d0?, 0x2, 0x2}, {0xc0000372f0?, 0x1, 0x0?})
	/Users/phil/work/zed/pkg/charm/path.go:11 +0x8b
github.com/brimdata/zed/pkg/charm.(*Spec).ExecRoot(0x165ba60?, {0xc0000372c0, 0x4, 0x4})
	/Users/phil/work/zed/pkg/charm/charm.go:63 +0x4a
main.main()
	/Users/phil/work/zed/cmd/zq/main.go:14 +0x1ea
@philrz philrz added the bug Something isn't working label Mar 4, 2023
@philrz
Copy link
Contributor Author

philrz commented Apr 19, 2024

I just came across this issue during a bug scrub and only then realized that I recently bumped into it again and opened a new issue #5107. Since that issue has two separate panic examples I'll close this one as a duplicate.

@philrz philrz closed this as not planned Won't fix, can't repro, duplicate, stale Apr 19, 2024
@philrz philrz added the duplicate This issue or pull request already exists label Apr 19, 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 duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

1 participant