Repository navigation
feat(replay): Add pauseTouchTracking and resumeTouchTracking - #7030
Conversation
Semver Impact of This PR⚪ None (no version bump detected) 📋 Changelog PreviewThis is how your changes will appear in the changelog.
Plus 4 more 🤖 This preview updates automatically when you update the PR. |
|
From running the skill on open PRs (#7042, #7030): a "Not verifiable this way" verdict decided before any build (build-only claims, triggers a simulator can't produce, native APIs missing from the pinned SDK, low disk), guidance for feature PRs and open PRs, checks for node_modules, run tagging and spec codegen, release builds by default, and evidence for replay recording content and JS-thread blocks. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* chore(tooling): Add verify-pr skill for on-device PR verification Adds a local skill that verifies a PR end to end on an Android emulator: build the sample without and with the change, drive it with Maestro, find both runs' events in sentry-sdks through the Sentry MCP, and write a draft before/after report. The sample tags events with verify.pr, verify.commit and verify.run_id when launched with matching launch arguments, and does nothing otherwise. It also enables logs in sentry.options.json, so native Android matches the JS enableLogs setting. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * chore(tooling): Write verify-pr scenarios per run, not into the skill Scenarios were one-off per PR and nothing runs them, so a shared folder would grow and rot. Move the #7087 flow to flows/examples/ as the worked example and regression check, write each run's flow next to its report, and promote to flows/steps/ only when a second run needs it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * chore(tooling): Add iOS simulator support to the verify-pr skill From verifying #7087 and #6974 on the iOS simulator: Pods setup and the files pod install rewrites, the iOS init path, Maestro differences (no `back`, tab icons and the Playground tab need ids), reading screenshot attachments back from Sentry, and a two-color probe for masking checks. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * chore(tooling): Fold iOS acceptance-run findings into verify-pr Save the revert as a patch file, compare dist/ against packages/core/src, define verify.commit for both sides, reinstall Pods every iOS run, shut down booted devices, and keep attachment URLs out of reports. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * chore(sample): Add a screenshot masking probe to the Playground tab A two-color view inside the existing <Sentry.Mask> demo, plus a button that captures an exception with the demo on screen. The view is neither text nor an image, so only <Sentry.Mask> can hide it in the event's screenshot; a masked probe is one flat color. Used to verify #6974. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * chore(tooling): Add a pre-build gate and open-PR handling to verify-pr From running the skill on open PRs (#7042, #7030): a "Not verifiable this way" verdict decided before any build (build-only claims, triggers a simulator can't produce, native APIs missing from the pinned SDK, low disk), guidance for feature PRs and open PRs, checks for node_modules, run tagging and spec codegen, release builds by default, and evidence for replay recording content and JS-thread blocks. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
|
Heads-up: the native side is now unblocked on both platforms. Android already bundles sentry-android 8.66.0 (it has |
Bridge the native touch tracking pause to the shared Replay API, so apps can stop recording touch positions on sensitive screens, such as a custom PIN pad, while the masked screen recording continues. On Web the calls are logged no-ops, like pause(). Requires sentry-android 8.65.0 and sentry-cocoa 9.35.0. Fixes RN-673 Fixes #6299 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
861699c to
b18dbe8
Compare
🚨 Detected changes in high risk code 🚨High-risk code has higher potential to break the SDK and may be hard to test. To prevent severe bugs, apply the rollout process for releasing such changes and be extra careful when changing and reviewing these files:
|
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
🚨 Detected changes in high risk code 🚨High-risk code has higher potential to break the SDK and may be hard to test. To prevent severe bugs, apply the rollout process for releasing such changes and be extra careful when changing and reviewing these files:
|
📲 Install BuildsAndroid
|
## DESCRIBE YOUR PR Documents the new `pauseTouchTracking()` and `resumeTouchTracking()` Session Replay APIs for Android, Apple, React Native and Flutter, in a new "Pause Touch Tracking" section under "Manual Control" on each Session Replay page. The APIs stop recording touches on sensitive screens, such as a custom PIN pad, while the masked screen recording continues. SDK PRs: - Android: getsentry/sentry-java#6546 (merged) - Apple: getsentry/sentry-cocoa#9587 - React Native: getsentry/sentry-react-native#7030 - Flutter: getsentry/sentry-dart#4166 The version numbers in the text are the expected next releases: Android 8.65.0, Apple 9.35.0, React Native 8.36.0, Flutter 10.5.0. The hybrid SDKs can only ship after the native releases, so their numbers are the least certain. Please do not merge before all SDK PRs are released, and update the numbers if the release versions differ. ## IS YOUR CHANGE URGENT? - [ ] Urgent deadline (GA date, etc.): YYYY-MM-DD - [ ] Other deadline: YYYY-MM-DD - [x] No deadline: Not urgent, can wait up to 1 week+ ## SLA - Teamwork makes the dream work, so please add a reviewer to your PRs. - Please give the docs team up to 1 week to review your PR unless you've supplied a deadline. Thanks in advance for your help! ## PRE-MERGE CHECKLIST _Make sure you've checked the following before merging your changes:_ - [ ] Checked Vercel preview for correctness, including links - [ ] PR was reviewed and approved by any necessary SMEs (subject matter experts) - [ ] PR was reviewed and approved by a member of the [Sentry docs team](https://github.com/orgs/getsentry/teams/docs) 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Antonis Lilis <antonis.lilis@gmail.com>
📢 Type of change
📜 Description
Adds
pauseTouchTracking()andresumeTouchTracking()to the sharedReplayinterface. While touch tracking is paused, the native SDKs record no touch positions, but the masked screen recording continues. Breadcrumbs are not affected.This is a bridge only; the behavior lives in the native SDKs:
pause()/resume().resume()does not resume touch tracking.resumeTouchTracking()clears it, also across new replays andstop()/start(). It can be called before a replay starts.The calls are wired exactly like
pause/resume: fire-and-forget throughfireReplayControl→NATIVE.pauseReplayTouchTracking()/resumeReplayTouchTracking()→Sentry.replay().pauseTouchTracking()on Android andSentrySDK.internal.replay.pauseTouchTracking()on iOS. On Web they are logged no-ops, likepause().Important
Blocked on native releases. The native code calls APIs from getsentry/sentry-java#6546 (merged, ships in sentry-android 8.65.0) and getsentry/sentry-cocoa#9587 (open, 9.35.0 at the earliest). The Android and iOS builds fail until both versions are bumped here.
Both new methods are required members of the public
Replayinterface, likepause/resume. Code that implementsReplayitself must add them.💡 Motivation and Context
Masking hides sensitive content such as a custom PIN pad or a masked
WebView, but the recorded touch positions can still reveal the input.pause()already stops touches, but it also stops the screen recording, which some apps want to keep.Fixes #6299
Fixes RN-673
Docs: getsentry/sentry-docs#20711
💚 How did you test it?
JS unit tests in
mobilereplay.test.ts,browserReplay.test.tsandwrapper.test.ts(each method calls only its own native control, a failed call is logged, the calls do nothing when native is disabled or the method is missing). The AndroidRNSentryReplayControlTestand the iOSRNSentryReplayControlTestscover the new methods, but they can only run after the native bumps. The sample app's Playground tab has buttons for both methods.📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps
Bump sentry-android to 8.65.0 and sentry-cocoa to 9.35.0, then mark ready for review.
🤖 Generated with Claude Code