-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Using "Loader Script" create a lot eventos of TypeError: null is not an object (evaluating 'co.document.body.appendChild') #13707
Comments
Hello @jwv thanks for writing in. I tried this out locally with the following file and couldn't reproduce:
Running it via Do you have a minimal reproduction repo or stackblitz? |
Hello @andreiborza thanks for take some time to analyze the problem. I also can't reproduce this problem either, appears to be some combination of OS, Browser and Internet connection. Did you take the time to review the events I sent you in the links? Later i will create stackblitz and try to debug this events. It's not a big problem because i can always filtered out this events. Thank you again. |
@jwv I had a look at the events but couldn't really tell what the issue is from there sorry. |
Hey, I took a quick look and realistically, the only way how this could happen is that So my running theory is that some "exotic" browser doesn't automatically add a body element 🤔 This very likely originates from We could/should guard this, or use a similar mechanism as in our loader script to work around this. I'll take a look if we can fix this easily. sentry-javascript/packages/browser/test/loader.js Lines 65 to 101 in e1783a6
|
This was released with https://github.com/getsentry/sentry-javascript/releases/tag/8.31.0 - thanks for the GH issue @jwv! |
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/browser
SDK Version
8.30.0
Framework Version
No response
Link to Sentry event
https://fptic.sentry.io/issues/5739481656/?project=4504650871209984
https://fptic.sentry.io/issues/5738977641/?project=4504650871209984
https://fptic.sentry.io/issues/5739065410/?project=4504650871209984
https://fptic.sentry.io/issues/5739243469/?project=4504650871209984
Reproduction Example/SDK Setup
Steps to Reproduce
Using "Loader Script" with only "Enable Performance Monitoring" enabled.
This configuration will create a lot of events on sentry about:
TypeError: null is not an object (evaluating 'co.document.body.appendChild')
File: https://browser.sentry-cdn.com/8.30.0/bundle.tracing.min.js
Expected Result
No events created.
Actual Result
TypeError: null is not an object (evaluating 'co.document.body.appendChild')
The text was updated successfully, but these errors were encountered: