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

Beginner questions / why is sentry not tracking events? #346

Closed
iparker opened this issue Sep 14, 2021 · 6 comments
Closed

Beginner questions / why is sentry not tracking events? #346

iparker opened this issue Sep 14, 2021 · 6 comments
Labels

Comments

@iparker
Copy link

iparker commented Sep 14, 2021

Hello,

I try to integrate sentry into an nuxt application but I don't see any events online. Also I see no requests send to sentry in the network requests. I installed the module and set the dns in nuxt.config but it does not work.

So my questions are:

1.) Is this sentry module also working in dev-environment?

2.) Which kind of project/integration type do I have to choose in sentry? VueJS or Other? I think "Other" is correct, I tried both but it isn't working.

3.) Will sentry also log all errors displayed in console or just exceptions I send to sentry (like this.$sentry.captureException(new Error('example')); )? Should be every error in console automatically appear in sentry?

Do I need to enable any special option or do something else?

Thanks for some help with this!

Best regards,

Timo

@rchl
Copy link
Member

rchl commented Sep 14, 2021

  1. It's enabled in development also, unless explicitly disabled
  2. The type of integration on Sentry side most likely doesn't matter. It's mostly just a cosmetic choice.
  3. This module captures all unhandled exceptions so including the ones that show up in the console.

This module prints some logs on starting Nuxt app. What do those say?

@iparker
Copy link
Author

iparker commented Sep 14, 2021

Damn - you are right! I placed the sentry-config in nuxt.config in wrong order. Fixed this it is instantly working! Thanks a lot!

But one more question:

Currently I don't see my console-errors in sentry. I have console output like this:

GET http://localhost:1337/uploads/home_hero_a654f8a229.jpg 404 (Not Found) --> Image not found

[Vue warn]: Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. --> Problem with vue component

Error in fetch(): TypeError: section.base_data.title.replaceAll is not a function --> Error in script

Unchecked runtime.lastError: The message port closed before a response was received. --> Another output in console

Is there a way to get this output also in sentry? Or what kind of errors are tracked in sentry?

@rchl
Copy link
Member

rchl commented Sep 14, 2021

Looks like you are hitting #245 - known issue with exceptions within fetch not being captured.

@iparker
Copy link
Author

iparker commented Sep 14, 2021

Again thanks a lot for your quick reply!

The issue with exceptions in fetch is an important point.

And can you tell me something about the other points? Should an "not found"-get-request or an vue warning be visible in sentry?

My thought was that I will see all the output from the console in sentry. Currently I just see type errors.

@rchl
Copy link
Member

rchl commented Sep 14, 2021

Console logs are not captured by default. You can configure a CaptureConsole integration if you want that. See https://sentry.nuxtjs.org/sentry/options#clientintegrations

@iparker
Copy link
Author

iparker commented Sep 14, 2021

Great - thanks a lot! Now I see the console output in sentry. Thanks a lot!

@rchl rchl closed this as completed Sep 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants