Skip to content

Commit

Permalink
Auto merge of #2871 - Turbo87:transition-abort, r=jtgeibel
Browse files Browse the repository at this point in the history
sentry: Ignore `TransitionAborted` errors

According to emberjs/ember.js#18416 it looks like changing query params that have `refreshModel: true` causes an internal `TransitionAborted` error. This error is being ignored by Ember itself (see https://github.com/emberjs/ember.js/blob/v3.21.3/packages/`@ember/-internals/runtime/lib/ext/rsvp.js#L40-L42),` but Sentry also hooks into `RSVP.on('error')` and unfortunately reports these false positives (see emberjs/ember.js#12505)

This PR actively ignores `TransitionAborted` errors in the `beforeSend()` hook of Sentry.

r? `@jtgeibel`
  • Loading branch information
bors committed Oct 4, 2020
2 parents eeff853 + e665842 commit 0df70a5
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions app/sentry.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,17 @@ export function init() {
environment,
...config.sentry,
integrations,

beforeSend(event, hint) {
let error = hint?.originalException;

// Ignoring these errors due to https://github.com/emberjs/ember.js/issues/12505
// and https://github.com/emberjs/ember.js/issues/18416
if (error && error.name === 'TransitionAborted') {
return null;
}

return event;
},
});
}

0 comments on commit 0df70a5

Please sign in to comment.