Skip to content

Emit partial stderr output from child on maxBuffer exceeded - #181

Merged
jamiebuilds merged 1 commit into
lerna:masterfrom
gigabo:partial-stderr
Jun 9, 2016
Merged

jamiebuilds merged 1 commit into
lerna:masterfrom
gigabo:partial-stderr

Conversation

@gigabo

@gigabo gigabo commented Jun 6, 2016

Copy link
Copy Markdown
Contributor

If the error from child.exec is just that the child process emitted too much
on stderr, then that stderr output is likely to be useful. Emit as much as
possible, with a warning that it's partial output.

If the error from `child.exec` is just that the child process emitted too much
on stderr, then that stderr output is likely to be useful.  Emit as much as
possible, with a warning that it's partial output.
@gigabo

gigabo commented Jun 6, 2016

Copy link
Copy Markdown
Contributor Author

I was seeing output like this from lerna run test:

image

This patch let me see the stderr output, which helped me track down what was actually going wrong.

@gigabo

gigabo commented Jun 6, 2016

Copy link
Copy Markdown
Contributor Author

Looks like a test failed on one of the environments. npm run ci passed locally (and passes on the other two environments in travis). Noticed that #179 also had an unexpected failure in one build environment, though the error output looks different. Something intermittent going on? I'm unable to restart the test to check.

@gigabo

gigabo commented Jun 7, 2016

Copy link
Copy Markdown
Contributor Author

Thanks for rerunning the tests.

@hzoo

hzoo commented Jun 8, 2016

Copy link
Copy Markdown
Contributor

👍

err = `Error: ${err.message}. Partial output follows:\n\n${stderr}`;
}

callback(err || stderr);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

There's probably a better way to format this callback with the err and stderr output. But this is fine for now

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We can merge and leave a TODO/issue to cleanup

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Hey, I don't want to let this slip through the cracks, but I'm actually not sure what the TODO is here. 😅

@jamiebuilds
jamiebuilds merged commit 05da182 into lerna:master Jun 9, 2016
gigabo added a commit to gigabo/react-server that referenced this pull request Jun 10, 2016
This picks up some patches that will help us out:

- lerna/lerna#181
- lerna/lerna#196
- lerna/lerna#198
- lerna/lerna#199
gigabo added a commit to redfin/react-server that referenced this pull request Jun 13, 2016
* Upgrade lerna-2.0.0-beta.18

This picks up some patches that will help us out:

- lerna/lerna#181
- lerna/lerna#196
- lerna/lerna#198
- lerna/lerna#199

* Use `lerna clean` for `npm run nuke`
davidalber pushed a commit to davidalber/react-server that referenced this pull request Jul 24, 2016
* Upgrade lerna-2.0.0-beta.18

This picks up some patches that will help us out:

- lerna/lerna#181
- lerna/lerna#196
- lerna/lerna#198
- lerna/lerna#199

* Use `lerna clean` for `npm run nuke`
@lock

lock Bot commented Dec 28, 2018

Copy link
Copy Markdown

This thread has been automatically locked because there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock Bot locked as resolved and limited conversation to collaborators Dec 28, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants