Skip to content
This repository was archived by the owner on Oct 2, 2021. It is now read-only.

Change the way error message is surfaced up to the UI. #303

Merged
merged 1 commit into from
Mar 13, 2018

Conversation

changsi-an
Copy link
Contributor

Please see the inline comment.

error.message + ': ' + error.data :
(error.stack || error.message);
(error.message || error.stack);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

error.message is more user friendly than error.stack(which is a stack for the DA itself, not the user code). So when reporting an error to the UI, we let error.message take priority.

The original message is put to errDiagnosticMsg, and emitted by the Output event. So we are not losing anything with this code change. If user is interested, s/he can still find the callstack in the output pane.

@roblourens roblourens merged commit 21d39ec into microsoft:master Mar 13, 2018
@roblourens roblourens added this to the March 2018 milestone Apr 3, 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.

2 participants