-
-
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
Transactions for ui.vue.update
are sometimes created instead of spans
#13546
Comments
This temporarily disables Sentry Vue component tracking until Sentry issues are resolved: * getsentry/sentry-javascript#13510 * getsentry/sentry-javascript#13546
Thanks for your comprehensively described issue! When the page is hidden, the transaction is finished and will be sent to sentry. So it's not really possible to change the name afterwards. One thing you could do is change the transaction name in About the second thing you mentioned: This would need a reproduction but I get that this is difficult with the custom integration. It could also be an issue with the default |
Is it possible to stop finishing transactions when the page is hidden?
Unfortunately, I still wasn't able to reproduce it myself, but it continues to happen for a few users: It appears that it happens when the |
You could try setting
And I will try to create an E2E test to check this behavior. We have an idea why this might be happening. |
I could not reproduce it but I added a change that does not create UI spans if there is no root span: #13568 I will close the issue for now, but feel free to re-open it if you still experience weird behavior or if you are able to reproduce the issue. |
UI spans make sense if they are a child of e.g. a pageload root span. This change ensures UI spans are not created as root spans. ref #13546
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/vue
SDK Version
8.27.0
Framework Version
Vue 3.4.38
Link to Sentry event
No response
Reproduction Example/SDK Setup
I'm using a custom
browserTracingIntegration
function that names transactions in a specific way, but it's based on the normal Vue router instrumentation. So, it's possible that this issue is caused by the error in my code. In this case, I would like to know how to fix it.Steps to Reproduce
Because I'm using custom integration, it's hard to fully reproduce this. I also wasn't able to reproduce it myself, I've only seen on Sentry that it happened to a few users.
Expected Result
All transactions should be named according to the rules in my custom integration, and
ui.vue.update
and other events should be created as spans on thepageload
ornavigation
transaction.Actual Result
There seem to be two (slightly related) issues:
Sometimes, transaction names are not parametrized according to the route params, but instead use raw URLs:
This appears to happen because the user hides the page while the document is loading, so the transaction is cancelled with
sentry.cancellation_reason document.hidden
and sent to Sentry before the Sentry code in the Vue router guard could rename it. This also happens with the default Sentry Vue integration. It's quite easy to reproduce this by adding some delay in another navigation guard and hiding the page before the Sentry integration code runs.In this case, I would expect that once the Sentry guard executed, it renamed the (already cancelled) transaction to the correct name.
Another issue is that events for component tracing like
ui.vue.update - Vue <<VAppBar>>
are sometimes created as new transactions instead of spans in the originalpageload
/navigation transaction
:This issue seems to have a similar reason as above, as the
pageload
transaction has been cancelled withsentry.cancellation_reason document.hidden
. However, I could not reproduce it myself, so I don't know if it also happens with the default integration.I would expect that these events were added to the original transaction as spans, even though it has been cancelled, or at least discarded, instead of creating incorrect transactions.
The text was updated successfully, but these errors were encountered: