Performance spans (app start, TTFD) currently carry no device condition context. When a slow startup is reported, there's no way to determine if it was caused by device throttling, low battery, or poor network conditions without manually correlating breadcrumbs.
Attaching the current device state as structured attributes on app start and TTFD spans would enable:
- Filtering: "show slow startups where thermal state was critical"
- Aggregation: "what % of slow starts happen on low battery?"
Feasibility Assessment (Jul 2026)
Not yet covered — zero device condition attributes on any spans in the RN SDK. Existing tracking issue #6340.
Cross-SDK alignment: Partially aligned.
- Flutter/Dart: Has attribute constants defined (
device.battery_level, device.charging, device.thermal_state, device.connection_type) and projection plumbing in SentryDevice.toAttributes(), but values are never actually populated from native side. End-to-end pipeline is incomplete.
- Android/Java: Has open issue #3545 for device condition on spans. Event context + breadcrumbs only today, not span attributes.
- Cocoa: Event context + breadcrumbs only, not span attributes.
Spec: No develop.sentry.dev spec exists for device condition span attributes. The sentry-conventions repo has connectionType and effectiveConnectionType but no thermal/battery/power attributes. Dart's naming (device.battery_level, device.thermal_state) provides a starting point but is incomplete (missing device.low_power_mode) and some names need updating (connection_type deprecated in favor of network.connection.type).
Dashboard visibility: Trace Explorer supports filtering on custom span attributes — would be visible there but no dedicated Performance UI.
Blocked on:
- Conventions spec PR at develop.sentry.dev to standardize attribute names
- Native SDK bridge APIs in Cocoa and Java for on-demand device state snapshots (neither currently exposes this)
- Then RN implementation
Implementation
Requires native bridge methods on both platforms:
- iOS:
ProcessInfo.thermalState, UIDevice.batteryLevel, UIDevice.batteryState
- Android:
BatteryManager, PowerManager, ConnectivityManager
Attach snapshot values as span attributes at app start and TTFD span creation/finalization time. Should be coordinated cross-SDK rather than implemented in isolation.
Performance spans (app start, TTFD) currently carry no device condition context. When a slow startup is reported, there's no way to determine if it was caused by device throttling, low battery, or poor network conditions without manually correlating breadcrumbs.
Attaching the current device state as structured attributes on app start and TTFD spans would enable:
Feasibility Assessment (Jul 2026)
Not yet covered — zero device condition attributes on any spans in the RN SDK. Existing tracking issue #6340.
Cross-SDK alignment: Partially aligned.
device.battery_level,device.charging,device.thermal_state,device.connection_type) and projection plumbing inSentryDevice.toAttributes(), but values are never actually populated from native side. End-to-end pipeline is incomplete.Spec: No develop.sentry.dev spec exists for device condition span attributes. The
sentry-conventionsrepo hasconnectionTypeandeffectiveConnectionTypebut no thermal/battery/power attributes. Dart's naming (device.battery_level,device.thermal_state) provides a starting point but is incomplete (missingdevice.low_power_mode) and some names need updating (connection_typedeprecated in favor ofnetwork.connection.type).Dashboard visibility: Trace Explorer supports filtering on custom span attributes — would be visible there but no dedicated Performance UI.
Blocked on:
Implementation
Requires native bridge methods on both platforms:
ProcessInfo.thermalState,UIDevice.batteryLevel,UIDevice.batteryStateBatteryManager,PowerManager,ConnectivityManagerAttach snapshot values as span attributes at app start and TTFD span creation/finalization time. Should be coordinated cross-SDK rather than implemented in isolation.