You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Session replay (React Native): support v2 trigger groups (conditional recording) #4595
Mobile tracker for PostHog/posthog#35661 (Conditional Recording 3000). The replay trigger config is getting a v2 shape, and the mobile SDKs need to support it:
multiple trigger groups, e.g. (20% sampling + error event) or (linked flag + url)
minimum duration moving inside a group
per-SDK matching, e.g. 40% sampling on web and 33% on mobile
more trigger types on non-web SDKs (event and URL/screen triggers)
debug properties, so conditional recording can be debugged outside web too
Conclusion: Confirmed feature gap: React Native supports legacy conditional-recording fields but does not evaluate the v2 trigger-group configuration. Confidence: 96% Suggested labels:feature, feature/replay, feature/mobile, react-native, team/client-libraries
Confirmed as an open React Native parity gap.
RN currently implements the legacy sessionRecording.linkedFlag and eventTriggers fields (released in 4.52.0), but does not read version: 2 or triggerGroups. A v2 response therefore bypasses the existing legacy gates and can start recording without applying per-group conditions or sampling.
This should be handled as a coordinated conditional-recording change rather than a small parser update: it changes remote-config recording start conditions and can affect recording volume. Before implementation, align the mobile v2 wire contract and native-plugin requirements with iOS/Android, then add focused coverage for group OR/AND semantics, per-group sampling persistence across session rotation, event and screen matching, minimum-duration behavior, malformed/missing config, remote-config reloads, and debug-property emission.
Investigation
React Native's replay evaluator reads only legacy linkedFlag and eventTriggers from persisted SessionReplay configuration. It has no version === 2 or triggerGroups handling.
The RN event-trigger implementation stores one activated-session value and AND-combines all legacy conditions. It cannot represent multiple independent groups, each with its own match type, sampling decision, activation state, or minimum duration.
The browser remote-config schema defines v2 groups with id, name, sampleRate, optional minDurationMs, and event, URL, flag, and property conditions. Browser's v2 strategy persists sampling per group and registers replay debug properties.
No React Native implementation was found for v2 trigger-group parsing, group-level sampling, group minimum duration, URL/screen matching, property filtering, or replay debug properties.
The optional RN native plugin bridge exposes recording controls but no v2 trigger-group API, so JS/native responsibilities and minimum-duration support must be explicitly agreed before changing behavior.
This is a recording-start-condition and remote-config change. The replay incident guidance identifies these paths as capable of silently suppressing recordings or changing fleet-wide recording volume; failure behavior for absent, malformed, and delayed v2 config must be deliberate and tested.
Reason: The current legacy gate is localized, but v2 requires a state model for multiple independently sampled and activated groups, persistence across session changes, screen/URL semantics, duration handling, diagnostics, and coordination with the native replay SDKs. A direct field parser would not safely preserve the required semantics.
Fix PR skipped: An older related issue appears to cover the same report: #3796
Activity
github-actions commentedon Aug 21, 2026
AI triage for #4595
Conclusion: Confirmed feature gap: React Native supports legacy conditional-recording fields but does not evaluate the v2 trigger-group configuration.
Confidence: 96%
Suggested labels:
feature,feature/replay,feature/mobile,react-native,team/client-librariesConfirmed as an open React Native parity gap.
RN currently implements the legacy
sessionRecording.linkedFlagandeventTriggersfields (released in 4.52.0), but does not readversion: 2ortriggerGroups. A v2 response therefore bypasses the existing legacy gates and can start recording without applying per-group conditions or sampling.This should be handled as a coordinated conditional-recording change rather than a small parser update: it changes remote-config recording start conditions and can affect recording volume. Before implementation, align the mobile v2 wire contract and native-plugin requirements with iOS/Android, then add focused coverage for group OR/AND semantics, per-group sampling persistence across session rotation, event and screen matching, minimum-duration behavior, malformed/missing config, remote-config reloads, and debug-property emission.
Investigation
linkedFlagandeventTriggersfrom persistedSessionReplayconfiguration. It has noversion === 2ortriggerGroupshandling.id,name,sampleRate, optionalminDurationMs, and event, URL, flag, and property conditions. Browser's v2 strategy persists sampling per group and registers replay debug properties.Relevant files:
packages/react-native/src/posthog-rn.ts,packages/react-native/test/session-replay-event-triggers.spec.ts,packages/react-native/src/optional/OptionalPlugin.ts,packages/react-native/CHANGELOG.md,packages/browser-common/src/types/remote-config.ts,packages/browser/src/extensions/replay/external/recording-strategies.ts,packages/browser/playwright/mocked/session-recording/trigger-groups-v2.spec.ts,.agents/skills/replay-incident-risk/INCIDENTS.mdFix assessment
Fix PR skipped: An older related issue appears to cover the same report: #3796
Pi session
The resumable JSONL pi session for this run was saved to a private gist: https://gist.github.com/marandaneto/44dbb6b848b6ecd3dfd7c6785c8d904d
Download it locally, then fork it into your own pi session:
Saved session:
call-1-1-2026-08-21T10-12-41-432Z_01a023ce-f758-73db-a030-59d0a84ba00f.jsonlClose proposal
None. No issue close action was taken.
Generated by posthog-watcher-action using pi.