Closed as not planned
Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Sentry Saas (sentry.io)
Which package are you using?
@sentry/gatsby
SDK Version
7.12.1
Framework Version
Gatsby 4.14.1
Link to Sentry event
No response
Steps to Reproduce
Initialize the plugin in gatsby-config.js
:
module.exports = {
plugins: [
{
resolve: '@sentry/gatsby',
options: {
dsn: 'XXXX',
},
},
],
}
On the client (e.g. inside a component):
import * as Sentry from '@sentry/gatsby';
Sentry.captureException(new Error('error');
Expected Result
An exception should be sent to Sentry.
Actual Result
Nothing is sent to Sentry (nothing at sentry.io or in the browser's network tab) unless calling Sentry.init({ dns: 'XXXX' })
before calling Sentry.captureException()
. Unhandled exceptions are properly captured, but not manual calls to Sentry.captureException()
.