Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
### Fixes

- Fix potential app launch hang caused by the SentrySDK (#6181) Fixed by removing the call to `_dyld_get_image_header` on the main thread.
- Fix dyanmic selector crash in SentryReplayRecording (#6211)

## 8.56.0

Expand Down
4 changes: 0 additions & 4 deletions Sentry.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1102,7 +1102,6 @@
FA90FAFD2E070A3B008CAAE8 /* SentryURLRequestFactory.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA90FAFC2E070A3B008CAAE8 /* SentryURLRequestFactory.swift */; };
FA94E6912E6B92C100576666 /* SentryClientReport.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA94E68B2E6B92BE00576666 /* SentryClientReport.swift */; };
FA94E6B22E6D265800576666 /* SentryEnvelope.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA94E6B12E6D265500576666 /* SentryEnvelope.swift */; };
FA94E71C2E6F26C500576666 /* SentrySerialization+ReplayRecording.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA94E71B2E6F26BF00576666 /* SentrySerialization+ReplayRecording.swift */; };
FA94E7242E6F339400576666 /* SentryEnvelopeItemType.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA94E7232E6F32FA00576666 /* SentryEnvelopeItemType.swift */; };
FAAB29F12E3D252300ACD577 /* SentrySession.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAAB29F02E3D252000ACD577 /* SentrySession.swift */; };
FAAB2EE02E4BE97500FE8B7E /* TestSentryNSApplication.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAAB2EDF2E4BE96F00FE8B7E /* TestSentryNSApplication.swift */; };
Expand Down Expand Up @@ -2449,7 +2448,6 @@
FA90FAFC2E070A3B008CAAE8 /* SentryURLRequestFactory.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SentryURLRequestFactory.swift; sourceTree = "<group>"; };
FA94E68B2E6B92BE00576666 /* SentryClientReport.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SentryClientReport.swift; sourceTree = "<group>"; };
FA94E6B12E6D265500576666 /* SentryEnvelope.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SentryEnvelope.swift; sourceTree = "<group>"; };
FA94E71B2E6F26BF00576666 /* SentrySerialization+ReplayRecording.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "SentrySerialization+ReplayRecording.swift"; sourceTree = "<group>"; };
FA94E7232E6F32FA00576666 /* SentryEnvelopeItemType.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SentryEnvelopeItemType.swift; sourceTree = "<group>"; };
FAAB29F02E3D252000ACD577 /* SentrySession.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SentrySession.swift; sourceTree = "<group>"; };
FAAB2EDF2E4BE96F00FE8B7E /* TestSentryNSApplication.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TestSentryNSApplication.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -2607,7 +2605,6 @@
children = (
62CB19242E77F8FD00AF5DA2 /* SentryDispatchSourceWrapper.swift */,
FAEEC04C2E75E55A00E79CA9 /* SentrySerializationSwift.swift */,
FA94E71B2E6F26BF00576666 /* SentrySerialization+ReplayRecording.swift */,
FA94E7232E6F32FA00576666 /* SentryEnvelopeItemType.swift */,
FA458CBD2E691A6E0061B13D /* SentryProcessInfo.swift */,
F4A930222E65FDAF006DA6EF /* SentryMobileProvisionParser.swift */,
Expand Down Expand Up @@ -5691,7 +5688,6 @@
63FE711D20DA4C1000CDBAE8 /* SentryCrashCPU_arm64.c in Sources */,
844EDC77294144DB00C86F34 /* SentrySystemWrapper.mm in Sources */,
D451ED5F2D92ECDE00C9BEA8 /* SentryReplayFrame.swift in Sources */,
FA94E71C2E6F26C500576666 /* SentrySerialization+ReplayRecording.swift in Sources */,
D49480D72DC23FE300A3B6E9 /* SentrySessionReplayDelegate.swift in Sources */,
FA67DCC12DDBD4C800896B02 /* SentrySDKLog+Configure.swift in Sources */,
6281C5722D3E4F12009D0978 /* DecodeArbitraryData.swift in Sources */,
Expand Down
2 changes: 0 additions & 2 deletions Sources/Sentry/include/SentrySerialization.h
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
#import "SentryDefines.h"

@class SentryAppState;
@class SentryEnvelope;
@class SentryReplayRecording;
@class SentrySession;

NS_ASSUME_NONNULL_BEGIN
Expand Down
20 changes: 0 additions & 20 deletions Sources/Swift/Helper/SentrySerialization+ReplayRecording.swift

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@_implementationOnly import _SentryPrivate
import Foundation

@objcMembers
@_spi(Private) public class SentryReplayRecording: NSObject {
@objc @_spi(Private) public class SentryReplayRecording: NSObject {

static let SentryReplayEncoding = "h264"
static let SentryReplayContainer = "mp4"
Expand All @@ -13,7 +13,7 @@ import Foundation
let height: Int
let width: Int

public convenience init(segmentId: Int, video: SentryVideoInfo, extraEvents: [any SentryRRWebEventProtocol]) {
@objc public convenience init(segmentId: Int, video: SentryVideoInfo, extraEvents: [any SentryRRWebEventProtocol]) {
self.init(segmentId: segmentId, size: video.fileSize, start: video.start, duration: video.duration, frameCount: video.frameCount, frameRate: video.frameRate, height: video.height, width: video.width, extraEvents: extraEvents)
}

Expand All @@ -27,11 +27,28 @@ import Foundation
self.events = [meta, video] + (extraEvents ?? [])
}

public func headerForReplayRecording() -> [String: Any] {
func headerForReplayRecording() -> [String: Any] {
return ["segment_id": segmentId]
}

public func serialize() -> [[String: Any]] {
func serialize() -> [[String: Any]] {
return events.map { $0.serialize() }
}

func data() -> Data? {
var recording = Data()
guard let headerData = SentrySerialization.data(withJSONObject: headerForReplayRecording()) else {
SentrySDKLog.error("Failed to serialize replay recording header.")
return nil
}
recording.append(headerData)
let newLineData = Data(bytes: "\n", count: 1)
recording.append(newLineData)
guard let replayData = SentrySerialization.data(withJSONObject: serialize()) else {
SentrySDKLog.error("Failed to serialize replay recording data.")
return nil
}
recording.append(replayData)
return recording
}
}
Loading