Skip to content

Commit

Permalink
Ignore sending a bunch of errors to sentry
Browse files Browse the repository at this point in the history
- We've been through all of these and determined they're either inconsequential or non-interesting and are just using up our sentry req quota. Thus we're choosing to ignore these ones
  • Loading branch information
poltak committed May 17, 2024
1 parent c72552e commit d48d79f
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions src/util/raven.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ export default function initSentry({
shouldSendCallback: () => sentryEnabled,
whitelistUrls: [extUrlPattern],
includePaths: [extUrlPattern],
ignoreErrors: IGNORED_ERRORS,
})
.install()

Expand All @@ -48,3 +49,26 @@ export const captureException = (
) => raven.captureException(error, context)
export const captureBreadcrumb = (details: any) =>
raven.captureBreadcrumb(details)

const IGNORED_ERRORS = [
`No registered remote function called handleHistoryStateUpdate`,
`No registered remote function called confirmTabScriptLoaded`,
`No registered remote function called teardownContentScripts`,
`Error: Could not get a port to content-script-background`,
`Cannot destructure property 'id' of 'i' as it is undefined.`,
`NotAllowedError: Registration failed - permission denied`,
`An error occurred. See https://git.io/JUIaE#17 for more information.`,
`AbortError: Registration failed - push service error`,
`Could not establish connection. Receiving end does not exist.`,
`Error: Cannot inject content-scripts into page`,
`Error: No tab with id:`,
`Unable to download all specified images.`,
`Could not establish connection. Receiving end does not exist.`,
`A listener indicated an asynchronous response by returning true`,
`DatabaseClosedError: UnknownError`,
`DatabaseClosedError: InvalidStateError`,
`DatabaseClosedError: UpgradeError`,
`UpgradeError Not yet support for changing primary key`,
`Tried to do 'findObjects' operation on non-existing collection: settings`,
`Invariant Violation: update(): You provided an invalid spec to update().`,
]

0 comments on commit d48d79f

Please sign in to comment.