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

tools: show stdout/stderr for timed out tests #20260

Closed
wants to merge 1 commit into from

Conversation

Trott
Copy link
Member

@Trott Trott commented Apr 24, 2018

When a test times out, the contents of stdout and stderr can often be
highly valuable in debugging. Provide that information.

Refs: #19906 (comment)

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

When a test times out, the contents of stdout and stderr can often be
highly valuable in debugging. Provide that information.

Refs: nodejs#19906 (comment)
@nodejs-github-bot nodejs-github-bot added test Issues and PRs related to the tests. tools Issues and PRs related to the tools directory. labels Apr 24, 2018
@Trott
Copy link
Member Author

Trott commented Apr 24, 2018

@nodejs/build @nodejs/testing

@Trott
Copy link
Member Author

Trott commented Apr 24, 2018

@@ -333,7 +333,7 @@ def HasRun(self, output):
(total_seconds, duration.microseconds / 1000))
if self.severity is not 'ok' or self.traceback is not '':
if output.HasTimedOut():
self.traceback = 'timeout'
self.traceback = 'timeout\n' + output.output.stdout + output.output.stderr
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest to add a line break between stdout and stderr.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The way it's done here is the way it is done on line 291. Wanted to keep it consistent. Maybe a subsequent PR can change them both if there's agreement that a blank line would help.

@Trott Trott added author ready PRs that have at least one approval, no pending requests for changes, and a CI started. fast-track PRs that do not need to wait for 48 hours to land. labels Apr 24, 2018
Copy link
Member

@mhdawson mhdawson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Trott
Copy link
Member Author

Trott commented Apr 25, 2018

(Please 👍 for fast-tracking. Thanks!)

@BridgeAR
Copy link
Member

@Trott I personally believe that is already "accepted" due to adding the label earlier and getting a couple LGs later on without anyone saying something against it. That is at least how I understood, that we handled it so far.

@@ -333,7 +333,7 @@ def HasRun(self, output):
(total_seconds, duration.microseconds / 1000))
if self.severity is not 'ok' or self.traceback is not '':
if output.HasTimedOut():
self.traceback = 'timeout'
self.traceback = 'timeout\n' + output.output.stdout + output.output.stderr
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After reviewing #20295, do we expect anything in stderr/stdout if output.UnexpectedOutput() on L287 is false? If not can we simplify to self.traceback += '\ntimeout' as self.traceback is set on L291 with the contents of stderr/stdout.

@Trott
Copy link
Member Author

Trott commented Apr 25, 2018

@Trott I personally believe that is already "accepted" due to adding the label earlier and getting a couple LGs later on without anyone saying something against it. That is at least how I understood, that we handled it so far.

@BridgeAR I agree that's how people have been handling it, but I'm of the opinion that is in contradiction with the documented process, which at least implies that approval of fast-tracking should be explicit and not implicit like that. I've been pondering whether the documented process should be clarified to conform with current practice or if we should push for explicit fast-track approval. Until then, I intend to request explicit approval when I want to fast-track.

Copy link
Contributor

@refack refack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-1 to fast track

@refack refack removed the fast-track PRs that do not need to wait for 48 hours to land. label Apr 25, 2018
@refack
Copy link
Contributor

refack commented Apr 25, 2018

+1 for change, but IMHO this should be regular-tracked (RE: #19855 (comment))

/CC @rvagg

@rvagg
Copy link
Member

rvagg commented Apr 26, 2018

This is one area that we can't fully test the consequences of the change and may be surprised by the results. I don't know if that should impact fast-tracking or not, just a word of warning that we often find odd dependencies on output like this and we won't really know until we break it—or we just try not to break it by being extra care with our changes (e.g. like my objection to timeout -> Timed Out)

Trott added a commit to Trott/io.js that referenced this pull request Apr 27, 2018
When a test times out, the contents of stdout and stderr can often be
highly valuable in debugging. Provide that information.

Refs: nodejs#19906 (comment)

PR-URL: nodejs#20260
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: Gus Caplan <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
@Trott
Copy link
Member Author

Trott commented Apr 27, 2018

Landed in 169756b

@Trott Trott closed this Apr 27, 2018
MylesBorins pushed a commit that referenced this pull request May 4, 2018
When a test times out, the contents of stdout and stderr can often be
highly valuable in debugging. Provide that information.

Refs: #19906 (comment)

PR-URL: #20260
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: Gus Caplan <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
@MylesBorins MylesBorins mentioned this pull request May 8, 2018
MylesBorins pushed a commit that referenced this pull request Aug 17, 2018
When a test times out, the contents of stdout and stderr can often be
highly valuable in debugging. Provide that information.

Refs: #19906 (comment)

PR-URL: #20260
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: Gus Caplan <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
@MylesBorins MylesBorins mentioned this pull request Aug 17, 2018
@Trott Trott deleted the show-stdout-stderr branch January 13, 2022 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. test Issues and PRs related to the tests. tools Issues and PRs related to the tools directory.
Projects
None yet
Development

Successfully merging this pull request may close these issues.