Skip to content

Commit a3d948b

Browse files
committed
Merge remote-tracking branch 'origin/main' into philprime/session-replay-inversion-improvements
2 parents 3ff7c84 + 12e5006 commit a3d948b

File tree

4 files changed

+19
-6
lines changed

4 files changed

+19
-6
lines changed

.github/workflows/build.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,19 @@ jobs:
6969
- scheme: macOS-SwiftUI
7070
xcode: 16.2
7171
runs-on: macos-15
72+
7273
- scheme: SessionReplay-CameraTest
7374
xcode: 16.2
7475
runs-on: macos-15
76+
77+
# We have to compile on Xcode 16.3 because compiling on Xcode 16.2 fails with
78+
# Data+SentryTracing.swift:21:62: error: 'ReadingOptions' aliases 'Foundation.ReadingOptions'
79+
# and cannot be used here because C++ types from imported module 'Foundation' do not support
80+
# library evolution; this is an error in the Swift 6 language mode
81+
- scheme: visionOS-Swift
82+
xcode: 16.3
83+
runs-on: macos-15
84+
7585
steps:
7686
- uses: actions/checkout@v4
7787
- run: ./scripts/ci-select-xcode.sh ${{ matrix.xcode }}

Samples/visionOS-Swift/visionOS-Swift/VisionOSSwiftApp.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ struct VisionOSSwiftApp: App {
99
options.dsn = "https://[email protected]/5428557"
1010
options.debug = true
1111
options.tracesSampleRate = 1.0
12-
options.profilesSampleRate = 1.0
1312
options.attachScreenshot = true
1413
options.attachViewHierarchy = true
1514

Sources/Sentry/SentrySessionReplayIntegration.m

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,8 @@ - (void)setupWith:(SentryReplayOptions *)replayOptions
100100
{
101101
_replayOptions = replayOptions;
102102
_rateLimits = SentryDependencyContainer.sharedInstance.rateLimits;
103+
_dateProvider = SentryDependencyContainer.sharedInstance.dateProvider;
104+
103105
id<SentryViewRenderer> viewRenderer;
104106
if (enableExperimentalRenderer) {
105107
viewRenderer = [[SentryExperimentalViewRenderer alloc]
@@ -116,9 +118,8 @@ - (void)setupWith:(SentryReplayOptions *)replayOptions
116118
enableExperimentalMaskRenderer:enableExperimentalRenderer];
117119

118120
if (touchTracker) {
119-
_touchTracker = [[SentryTouchTracker alloc]
120-
initWithDateProvider:SentryDependencyContainer.sharedInstance.dateProvider
121-
scale:replayOptions.sizeScale];
121+
_touchTracker = [[SentryTouchTracker alloc] initWithDateProvider:_dateProvider
122+
scale:replayOptions.sizeScale];
122123
[self swizzleApplicationTouch];
123124
}
124125

@@ -137,6 +138,8 @@ - (void)setupWith:(SentryReplayOptions *)replayOptions
137138
createBackgroundDispatchQueueWithName:"io.sentry.session-replay.processing"
138139
relativePriority:-2];
139140

141+
// The asset worker queue is used to work on video and frames data.
142+
140143
[self moveCurrentReplay];
141144
[self cleanUp];
142145

@@ -267,7 +270,8 @@ - (void)resumePreviousSessionReplay:(SentryEvent *)event
267270
NSError *_Nullable removeError;
268271
BOOL result = [NSFileManager.defaultManager removeItemAtURL:lastReplayURL error:&removeError];
269272
if (result == NO) {
270-
SENTRY_LOG_ERROR(@"Can`t delete '%@': %@", SENTRY_LAST_REPLAY, removeError);
273+
SENTRY_LOG_ERROR(@"Can't delete '%@' with file item at url: '%@', reason: %@",
274+
SENTRY_LAST_REPLAY, lastReplayURL, removeError);
271275
}
272276
}
273277

Sources/Swift/Integrations/SessionReplay/SentryOnDemandReplay.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ class SentryOnDemandReplay: NSObject, SentryReplayVideoMaker {
119119

120120
func releaseFramesUntil(_ date: Date) {
121121
processingQueue.dispatchAsync {
122-
SentryLog.debug("[Session Replay] Releasing frames until date: \(date), current queue: \(self.processingQueue.queue.label)")
122+
SentryLog.debug("[Session Replay] Releasing frames until date: \(date)")
123123
while let first = self._frames.first, first.time < date {
124124
self._frames.removeFirst()
125125
let fileUrl = URL(fileURLWithPath: first.imagePath)

0 commit comments

Comments
 (0)