Open MattDodsonEnglish opened 1 year ago
This is a bug ... of sorts.
The in k6 implementation does by default add a bunch of new lines. And I feel like that should just not be needed. As without them parts of the end summary got eaten up by other parts that are written over.
I don't know if this was done due to some kind of deficiency that we intend on fixing or what.
cc @na-- any memories as you were the one that implemented this originally
As current workaround - copy the linked code.
I don't know if this was done due to some kind of deficiency that we intend on fixing or what.
No, the newlines definitely were not there to avoid overwriting by the progress bars, they were added to make the JS summary output identical to the old k6 Go code that produced the same summary.
The problem probably occurs because we use terminal control codes to control the terminal "cursor" (caret?) and essentially print the progressbars in the same place. I might have messed up something in https://github.com/grafana/k6/pull/2815 that caused the last progressbar printing to overwrite the last line of the end-of-test summary :thinking: Or this bug might have existed before even that.
In either case, we should probably finish with the progress bars before we handle the end-of-test summary, which should resolve this bug too :thinking:
Brief summary
In this script, one custom trend,
wsw_time
, disappears from the console output when I use thehandleSummary
with thetextSummary
from the jslib. Strangely, I think it didn't happen every time, either. Sorry I can't confirm that it's only occasionally reproducible, but I can attach a screenshot of a time it didn't appear.Not that the other custom metric,
their_time
shows up fine in both cases.k6 version
k6 v0.44.0 ((devel), go1.20.3, linux/amd64)
OS
Arch linux, installed through AUR
Docker version and image (if applicable)
No response
Steps to reproduce the problem
Run script attached
Expected behaviour
wsw_time
summary appears in handleSummary terminal output.Actual behaviour
wsw_time
doesn't appear.