Skip to content

Commit f2d10b7

Browse files
fix(react-navigation): Make navigation.processing span title more explicit (#4423)
1 parent 94572f6 commit f2d10b7

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@
88
99
## Unreleased
1010

11+
### Changes
12+
13+
- Rename `navigation.processing` span to more expressive `Navigation dispatch to screen A mounted/navigation cancelled` ([#4423](https://github.com/getsentry/sentry-react-native/pull/4423))
14+
1115
### Dependencies
1216

1317
- Bump CLI from v2.39.1 to v2.40.0 ([#4412](https://github.com/getsentry/sentry-react-native/pull/4412))

packages/core/src/js/tracing/reactnavigation.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ export const reactNavigationIntegration = ({
203203
if (enableTimeToInitialDisplay) {
204204
navigationProcessingSpan = startInactiveSpan({
205205
op: 'navigation.processing',
206-
name: 'Navigation processing',
206+
name: 'Navigation dispatch to navigation cancelled or screen mounted',
207207
startTime: latestNavigationSpan && spanToJSON(latestNavigationSpan).start_timestamp,
208208
});
209209
navigationProcessingSpan.setAttribute(
@@ -274,7 +274,7 @@ export const reactNavigationIntegration = ({
274274
});
275275
}
276276

277-
navigationProcessingSpan?.updateName(`Processing navigation to ${route.name}`);
277+
navigationProcessingSpan?.updateName(`Navigation dispatch to screen ${route.name} mounted`);
278278
navigationProcessingSpan?.setStatus({ code: SPAN_STATUS_OK });
279279
navigationProcessingSpan?.end(stateChangedTimestamp);
280280
navigationProcessingSpan = undefined;

packages/core/test/tracing/reactnavigation.ttid.test.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ describe('React Navigation - TTID', () => {
204204
'sentry.origin': SPAN_ORIGIN_AUTO_NAVIGATION_REACT_NAVIGATION,
205205
'sentry.source': 'custom',
206206
},
207-
description: 'Processing navigation to New Screen',
207+
description: 'Navigation dispatch to screen New Screen mounted',
208208
op: 'navigation.processing',
209209
origin: SPAN_ORIGIN_AUTO_NAVIGATION_REACT_NAVIGATION,
210210
status: 'ok',
@@ -232,7 +232,7 @@ describe('React Navigation - TTID', () => {
232232
'sentry.origin': SPAN_ORIGIN_AUTO_NAVIGATION_REACT_NAVIGATION,
233233
'sentry.source': 'custom',
234234
},
235-
description: 'Processing navigation to Initial Screen',
235+
description: 'Navigation dispatch to screen Initial Screen mounted',
236236
op: 'navigation.processing',
237237
origin: SPAN_ORIGIN_AUTO_NAVIGATION_REACT_NAVIGATION,
238238
status: 'ok',

0 commit comments

Comments
 (0)