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

Can i send error event manually? #8806

Closed
3 tasks done
yayapao opened this issue Aug 14, 2023 · 3 comments
Closed
3 tasks done

Can i send error event manually? #8806

yayapao opened this issue Aug 14, 2023 · 3 comments

Comments

@yayapao
Copy link

yayapao commented Aug 14, 2023

Is there an existing issue for this?

How do you use Sentry?

Self-hosted/on-premise

Which SDK are you using?

@sentry/browser

SDK Version

6.19

Framework Version

No response

Link to Sentry event

No response

SDK Setup

Sentry.init({
      dsn: 'SENTRY DSN',
      sampleRate: 1,
      debug: true,
})

Steps to Reproduce

  1. Import @sentry/browser package;
  2. Init the Sentry;
  3. Trigger an error event, and use Sentry.captureException to handle catch processor;

Expected Result

Send the error event, but it can't work all the client, such as QQ mobile browser. However, when i send event by store/ API, it worked. So i wonder if there is any method i can send the error event manually?

Actual Result

Actually, debugging on QQ mobile browser is a hard work.

@lforst
Copy link
Member

lforst commented Aug 14, 2023

The steps you mentioned should work. Please note that you're on quite an old SDK version though.

Can you please elaborate what exactly does not work? Thanks!

@yayapao
Copy link
Author

yayapao commented Aug 15, 2023

Thanks for your reply. Actually it works in most situations, but just can't work in QQ mobile browser, both 6.13 or 6.19.6.

  1. i publish a web page and generate the QR code;
  2. open the QQ, and scan the QR code;
  3. trigger the button to captureException;

Then nothing happened.
So i wonder if there is a native method allowing me to send event, it can be a plan B for most complex client situation.

@HazAT
Copy link
Member

HazAT commented Aug 15, 2023

We never tested it with QQ mobile browser - there might be some ad-blocking going on or something.
The most native way you send a request is to send a JSON payload to /store https://develop.sentry.dev/sdk/store/ but you would need to do it yourself.
Our SDK doesn't provide a more low-level API than captureException to do this.

I am closing this issue for now since there is not much to do for us and I am not even sure how we could test what's going wrong in QQ Browser.

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

No branches or pull requests

3 participants