Session replays recording while app is in background
hammoudma opened this issue · 7 comments
OS:
- Windows
- MacOS
- Linux
Platform:
- iOS
- Android
SDK:
-
@sentry/react-native
(>= 1.0.0) -
react-native-sentry
(<= 0.43.2)
SDK version: 8.33.0
react-native
version: 0.74.0
Are you using Expo?
- Yes
- No
Are you using sentry.io or on-premise?
- sentry.io (SaaS)
- on-premise
Configuration:
(@sentry/react-native
)
Sentry.init({
dsn: SENTRY_DSN,
environment: SENTRY_ENVIRONMENT,
_experiments: {
replaysSessionSampleRate: 0,
replaysOnErrorSampleRate: 1.0
},
integrations: [
Sentry.mobileReplayIntegration({
maskAllText: false,
maskAllImages: false
})
]
});
I have the following issue:
I am getting hours-long replay sessions of the app idling in the background. Is there a way to disable that?
I am assuming that that is also happening when the app is open and then the screen is locked.
Expected result:
I only get replays of user sessions were the user is using the app.
Hi @hammoudma,
thank you for the message,
could you describe more in detail, how to reproduce the behaviour?
I've tried to open our sample app, capture an error, lock the simulator screen and unlock it 10 minutes later, the replay shows the app was suspended for the 10 minutes.
Sorry I wasnt clear in the description, the replays I am getting are not of an error, they are just of the app idling for a long time.
For example, is there a way to get rid of these or limit the recording time
@hammoudma Thank you for the explanation. I understand now.
@brustolin @romtsn Does the current Replay length limit includes the inactive/paused replay time?
Technically, yes, but this should not happen. Once it goes into the background for more than 30 seconds, we should not consider it the same session.
Bump cocoa when getsentry/sentry-cocoa#4303 is released.