Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(gatsby): Package gatsby files properly #2711

Merged
merged 2 commits into from Jun 30, 2020
Merged

Conversation

AbhiPrasad
Copy link
Member

See: #2706

As it stands gatsby-browser.js and gatsby-node.js aren't properly packaged into
the @sentry/gatsby distribution. Because of this Sentry.init() is never called
and the Sentry module is never bound to the window - loading the plugin is
effectively a nop. Unfortunately, the failure is silent.

Thanks to @klittlepage for reporting.

@getsentry-bot
Copy link
Contributor

Messages
📖

@sentry/browser bundle gzip'ed minified size: (ES5: 17.1387 kB) (ES6: 16.252 kB)

📖 ✅ TSLint passed

Generated by 🚫 dangerJS against 87f46c1

@AbhiPrasad AbhiPrasad merged commit 0defcdc into master Jun 30, 2020
@AbhiPrasad AbhiPrasad deleted the abhi/fix/gatsby-dist branch June 30, 2020 13:46
@dcramer
Copy link
Member

dcramer commented Jun 30, 2020

Oof, sorry about that. I think I had tested it in a diff structure then copied over the files once its as working.

@swannknani
Copy link

swannknani commented Jul 8, 2020

@dcramer, @AbhiPrasad The plugin doesn't look to be loaded properly because of missing gatsby-* files inside the npm folder.

Screenshot 2020-07-08 at 15 14 11

version: "@sentry/gatsby": "5.19.1"

@webjay
Copy link

webjay commented Jul 17, 2020

With 5.19.2 I get Can't resolve '@sentry/apm'.
Should I install that, or should you?

@AbhiPrasad
Copy link
Member Author

AbhiPrasad commented Jul 17, 2020

@webjay Thank you for reporting, opened #2752 to make the change. For the time being, you can install the @sentry/apm package to get around any errors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants