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 the pageload or navigation 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 original pageload/navigation transaction:
This issue seems to have a similar reason as above, as the pageload transaction has been cancelled with sentry.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.
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
browserTracingIntegrationfunction 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.updateand other events should be created as spans on thepageloadornavigationtransaction.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.hiddenand 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
pageloadtransaction 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.