I have found a bug in xk6-tcp.
I cannot create a new issue in GitHub Grafana xk6-tcp.
GitHub replies
"Error
Unable to create issue."
Here is the bug report
xk6-tcp related panic due to nil passed as tagSet to handleError
k6 with xk6-tcp crash
panic: runtime error: invalid memory address or nil pointer dereference
atlas.(*Node).ValueByKey atlas.go:45
metrics.(*TagSet).Get tags.go:56
summary.(*Output).storeSample summary.go:177 <- sample.Tags.Get(TagCheck)
summary.(*Output).flushSample summary.go:86
summary.(*Output).flushMetrics summary.go:79
output.(*PeriodicFlusher).run helpers.go:69 <- runs every 200ms in its own goroutine
Suggested Patch to tcp/socket_read.go
- e := s.handleError(err, "read", nil)
+ // currentTags() must be used here (not nil) - handleError ultimately pushes
+ // a metrics.Sample with these tags, and a nil *metrics.TagSet crashes the
+ // summary/dashboard output's periodic flusher...
+ e := s.handleError(err, "read", s.currentTags())