hypothesis / h

Annotate with anyone, anywhere.
https://hypothes.is/
BSD 2-Clause "Simplified" License
2.94k stars 427 forks source link

Migrate from raven-js to @sentry/browser #8796

Closed robertknight closed 2 months ago

robertknight commented 3 months ago

Migrate frontend crash reporting from Sentry's old raven-js library to the modern @sentry/browser JS library.

Testing:

  1. Copy the DSN value from https://hypothesis.sentry.io/settings/projects/frontend-h/keys/
  2. Set the SENTRY_DSN_FRONTEND variable in h's environment to the DSN value
  3. Load a page in h, you should see a request to https://o18985.ingest.us.sentry.io/api/146908/envelope/
robertknight commented 2 months ago

Thanks @acelaya. I'll get this merged.

This worked for me, with the only consideration that the request to sentry results in a 403, but I assume that's expected and will work only from certain environments.

If you used the production Sentry DSN, then this is indeed expected, as there is a filter configured in Sentry to limit which domains error reports are accepted from.