Mailspring/spec/tasks
Evan Morikawa d4db0737cf feat(error): improve error reporting. Now NylasEnv.reportError
Summary:
The goal is to let us see what plugins are throwing errors on Sentry.

We are using a Sentry `tag` to identify and group plugins and their
errors.

Along the way, I cleaned up the error catching and reporting system. There
was a lot of duplicate error logic (that wasn't always right) and some
legacy Atom error handling.

Now, if you catch an error that we should report (like when handling
extensions), call `NylasEnv.reportError`. This used to be called
`emitError` but I changed it to `reportError` to be consistent with the
ErrorReporter and be a bit more indicative of what it does.

In the production version, the `ErrorLogger` will forward the request to
the `nylas-private-error-reporter` which will report to Sentry.

The `reportError` function also now inspects the stack to determine which
plugin(s) it came from. These are passed along to Sentry.

I also cleaned up the `console.log` and `console.error` code. We were
logging errors multiple times making the console confusing to read. Worse
is that we were logging the `error` object, which would print not the
stack of the actual error, but rather the stack of where the console.error
was logged from. Printing `error.stack` instead shows much more accurate
stack traces.

See changes in the Edgehill repo here: 8c4a86eb7e

Test Plan: Manual

Reviewers: juan, bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D2509
2016-02-03 18:06:52 -05:00
..
change-folder-task-spec.coffee Fix more task specs 2016-01-22 16:55:29 -08:00
change-labels-task-spec.coffee Fix more task specs 2016-01-22 16:55:29 -08:00
change-mail-task-spec.coffee feat(error): improve error reporting. Now NylasEnv.reportError 2016-02-03 18:06:52 -05:00
change-starred-task-spec.coffee
change-unread-task-spec.coffee
create-model-task-spec.es6 feat(metadata): add cloudState that sync with Metadata service 2016-02-02 15:28:06 -05:00
destroy-category-task-spec.coffee feat(error): improve error reporting. Now NylasEnv.reportError 2016-02-03 18:06:52 -05:00
destroy-model-task-spec.es6 feat(tasks): add Create, Update, Destroy tasks plus spec & lint fixes 2016-01-15 15:16:21 -05:00
event-rsvp-spec.coffee feat(tasks): add Create, Update, Destroy tasks plus spec & lint fixes 2016-01-15 15:16:21 -05:00
send-draft-spec.coffee feat(error): improve error reporting. Now NylasEnv.reportError 2016-02-03 18:06:52 -05:00
syncback-category-task-spec.coffee Merge branch 'master' into unified-inbox 2016-01-25 17:28:29 -08:00
syncback-draft-spec.coffee More spec fixes 2016-01-27 10:31:54 -08:00
syncback-model-task-spec.es6 feat(error): improve error reporting. Now NylasEnv.reportError 2016-02-03 18:06:52 -05:00
task-factory-spec.coffee fix(remove-from-view): Update remove from view (shortcut) behavior 2016-02-01 17:40:42 -08:00
task-spec.coffee feat(error): improve error reporting. Now NylasEnv.reportError 2016-02-03 18:06:52 -05:00
update-model-task-spec.es6 feat(tasks): add Create, Update, Destroy tasks plus spec & lint fixes 2016-01-15 15:16:21 -05:00