-
-
Couldn't load subscription status.
- Fork 1.7k
Closed as not planned
Closed as not planned
Copy link
Labels
Meta: Help WantedPackage: gatsbyIssues related to the Sentry Gatsby SDKIssues related to the Sentry Gatsby SDKhacktoberfest
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().
moy2010
Metadata
Metadata
Assignees
Labels
Meta: Help WantedPackage: gatsbyIssues related to the Sentry Gatsby SDKIssues related to the Sentry Gatsby SDKhacktoberfest