Skip to content

Better ember fastboot error message#237

Merged
tomdale merged 2 commits intomasterfrom
better-error-message
Jul 29, 2016
Merged

Better ember fastboot error message#237
tomdale merged 2 commits intomasterfrom
better-error-message

Conversation

@tomdale
Copy link
Copy Markdown
Contributor

@tomdale tomdale commented Jul 27, 2016

A previous commit caused stack traces to not be printed if there was an error while loading an app, making debugging much harder.

This commit reintroduces the stack trace to the logged output. It also tries to parse the stack trace and provide more helpful output for people who are not familiar with Ember's internals.

Example with exception from an addon:
1 ember fastboot node 2016-07-27 15-52-44

Example with exception from the app:
fastboot-test zsh 2016-07-27 15-48-37

@rwjblue
Copy link
Copy Markdown
Member

rwjblue commented Jul 27, 2016

This looks great, and a definite improvement!

I think a future revision could even use sourcemap information to help narrow things down even further.

@tomdale tomdale merged commit ec22f4d into master Jul 29, 2016
* Try to show a useful error message if we're not able to start the user's
* app in FastBoot.
*/
printError: function(e) {
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.

this function looks pretty complicated, it is likely a good idea to have unit tests covering it.

@stefanpenner stefanpenner deleted the better-error-message branch May 17, 2017 18:56
xg-wang pushed a commit to xg-wang/ember-cli-fastboot that referenced this pull request Nov 16, 2020
Add dev script to make tracing easier.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants