• Robert Knight's avatar
    Replace raven-js with Sentry's new JavaScript SDK · 542b96f0
    Robert Knight authored
    Replace the legacy raven-js package with Sentry's new JS SDK [1], with a
    minimal wrapper in `util/sentry.js` that exports the same interface as
    the previous `raven.js` module.
    
    To enable Sentry, h or the browser extension must set a `sentry` key in the
    sidebar app's configuration.
    
    As part of switching SDKs, the following changes were made:
    
     - The AngularJS integration was removed, as we are in the process of
       migrating away from Angular
     - The custom code for unhandled promise rejections was removed, as the
       new SDK handles this already
     - The URL rewriting logic was removed. This was done to make the setup
       as minimal as possible. This may need to be re-added later.
     - The `report` function was removed, as it was not used anywhere
     - The `session` module now imports `util/sentry` directly rather than
       using Angular dependency injection. Now that we have a convenient way
       to mock all CJS/ES imports, there isn't a need to use DI for
       utilities
    
    [1] https://docs.sentry.io/platforms/javascript/
    542b96f0
boot.js 3.47 KB