-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
logictest: improve progress output #72468
Conversation
Going to kick this over to @cockroachdb/sql-queries since they're the primary consumers of this format and ultimately need to be on board with the changes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r1, 1 of 1 files at r2, all commit messages.
Reviewable status: complete! 0 of 0 LGTMs obtained (waiting on @andreimatei)
pkg/sql/logictest/logic.go, line 1283 at r2 (raw file):
func (t *logicTest) outf(format string, args ...interface{}) { if t.verbose { finalArgs := make([]interface{}, 1+len(args))
nit: maybe add a quick comment what we're doing with this finalArgs
business.
I'm assuming that log.Infof
below doesn't need to work with finalArgs
because log
itself will add a timestamp?
Clarify that the test.progress field refers to statements executed, not "tests". Release note: None
Logictests would print some progress messages to stdout as they run. Each file prints when it ends and, while it's running, it prints messages when statements finish successfully (but only up to once per 2s). This patch adds a second-level timestamp to those messages, in order to provide more clues in the output of timed out logictest packages. Otherwise, I'm always left guessing if the package had been making constant progress until the timeout, or if it got stuck at some point. Release note: None
06a015e
to
3145a90
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: complete! 0 of 0 LGTMs obtained (waiting on @yuzefovich)
pkg/sql/logictest/logic.go, line 1283 at r2 (raw file):
nit: maybe add a quick comment what we're doing with this finalArgs business.
please see now
I'm assuming that log.Infof below doesn't need to work with finalArgs because log itself will add a timestamp?
right
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r3, 1 of 1 files at r4, all commit messages.
Reviewable status: complete! 1 of 0 LGTMs obtained (waiting on @andreimatei)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bors r+
Reviewable status: complete! 1 of 0 LGTMs obtained (waiting on @andreimatei)
Build failed (retrying...): |
This PR was included in a batch that was canceled, it will be automatically retried |
Build failed (retrying...): |
Build succeeded: |
Logictests would print some progress messages to stdout as they run.
Each file prints when it ends and, while it's running, it prints
messages when statements finish successfully (but only up to once per
2s). This patch adds a second-level timestamp to those messages, in
order to provide more clues in the output of timed out logictest
packages. Otherwise, I'm always left guessing if the package had been
making constant progress until the timeout, or if it got stuck at some
point.
Release note: None