Skip to content

Commit

Permalink
Merge branch 'main' into feat/replay
Browse files Browse the repository at this point in the history
  • Loading branch information
vaind authored Jun 4, 2024
2 parents 60d07df + fada0cd commit 41f816a
Show file tree
Hide file tree
Showing 7 changed files with 71 additions and 31 deletions.
18 changes: 15 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,21 @@ Access to Mobile Replay is limited to early access orgs on Sentry. If you're int
- Bump CLI from v2.30.4 to v2.31.2 ([#3719](https://github.com/getsentry/sentry-react-native/pull/3719))
- [changelog](https://github.com/getsentry/sentry-cli/blob/master/CHANGELOG.md#2312)
- [diff](https://github.com/getsentry/sentry-cli/compare/2.30.4...2.31.2)
- Bump Cocoa SDK from v8.25.0 to v8.25.2 ([#3802](https://github.com/getsentry/sentry-react-native/pull/3802))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8252)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.25.0...8.25.2)
- Bump Cocoa SDK from v8.26.0 to v8.27.0 ([#3858](https://github.com/getsentry/sentry-react-native/pull/3858))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8270)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.26.0...8.27.0)

## 5.22.3

### Fixes

- Missing `RNSentryOnDrawReporterView` on iOS ([#3832](https://github.com/getsentry/sentry-react-native/pull/3832))

### Dependencies

- Bump Cocoa SDK from v8.25.0 to v8.26.0 ([#3802](https://github.com/getsentry/sentry-react-native/pull/3802), [#3815](https://github.com/getsentry/sentry-react-native/pull/3815))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8260)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.25.0...8.26.0)

## 5.22.2

Expand Down
18 changes: 8 additions & 10 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ Comment out sentry dependency in `RNSentry.podspec`.

```diff
- s.dependency 'Sentry/HybridSDK', '7.31.0'
+ # s.dependency 'Sentry/HybridSDK', '7.31.0'
+ s.dependency 'Sentry/HybridSDK'
```

Add local pods to `sample/ios/Podfile`.
Expand All @@ -123,9 +123,7 @@ target 'sample' do

# ... react native config

+ pod 'Sentry/HybridSDK', :path => '../../../sentry-cocoa'
+ pod 'SentryPrivate', :path => '../../../sentry-cocoa/SentryPrivate.podspec'

pod 'Sentry/HybridSDK', :path => '../../../../sentry-cocoa'
# ... rest of the configuration

end
Expand All @@ -151,12 +149,12 @@ cd sentry-react-native/sample

Add local maven to `sample/android/build.gradle`.

```diff
+ allprojects {
+ repositories {
+ mavenLocal()
+ }
+ }
```gradle
allprojects {
repositories {
mavenLocal()
}
}
```

Update `sentry-android` version, to the one locally published, in `android/build.gradle`.
Expand Down
2 changes: 1 addition & 1 deletion RNSentry.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Pod::Spec.new do |s|
s.preserve_paths = '*.js'

s.dependency 'React-Core'
s.dependency 'Sentry/HybridSDK', '8.25.0-alpha.0'
s.dependency 'Sentry/HybridSDK', '8.27.0'

s.source_files = 'ios/**/*.{h,m,mm}'
s.public_header_files = 'ios/RNSentry.h'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
objects = {

/* Begin PBXBuildFile section */
33958C692BFCF12600AD1FB6 /* RNSentryOnDrawReporterTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 33958C682BFCF12600AD1FB6 /* RNSentryOnDrawReporterTests.m */; };
33AFDFED2B8D14B300AAB120 /* RNSentryFramesTrackerListenerTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 33AFDFEC2B8D14B300AAB120 /* RNSentryFramesTrackerListenerTests.m */; };
33AFDFF12B8D15E500AAB120 /* RNSentryDependencyContainerTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 33AFDFF02B8D15E500AAB120 /* RNSentryDependencyContainerTests.m */; };
33F58AD02977037D008F60EA /* RNSentryTests.mm in Sources */ = {isa = PBXBuildFile; fileRef = 33F58ACF2977037D008F60EA /* RNSentryTests.mm */; };
Expand All @@ -17,6 +18,8 @@
1482D5685A340AB93348A43D /* Pods-RNSentryCocoaTesterTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNSentryCocoaTesterTests.release.xcconfig"; path = "Target Support Files/Pods-RNSentryCocoaTesterTests/Pods-RNSentryCocoaTesterTests.release.xcconfig"; sourceTree = "<group>"; };
3360898D29524164007C7730 /* RNSentryCocoaTesterTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = RNSentryCocoaTesterTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
338739072A7D7D2800950DDD /* RNSentryTests.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RNSentryTests.h; sourceTree = "<group>"; };
33958C672BFCEF5A00AD1FB6 /* RNSentryOnDrawReporter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RNSentryOnDrawReporter.h; path = ../ios/RNSentryOnDrawReporter.h; sourceTree = "<group>"; };
33958C682BFCF12600AD1FB6 /* RNSentryOnDrawReporterTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNSentryOnDrawReporterTests.m; sourceTree = "<group>"; };
33AFDFEC2B8D14B300AAB120 /* RNSentryFramesTrackerListenerTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNSentryFramesTrackerListenerTests.m; sourceTree = "<group>"; };
33AFDFEE2B8D14C200AAB120 /* RNSentryFramesTrackerListenerTests.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RNSentryFramesTrackerListenerTests.h; sourceTree = "<group>"; };
33AFDFF02B8D15E500AAB120 /* RNSentryDependencyContainerTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNSentryDependencyContainerTests.m; sourceTree = "<group>"; };
Expand Down Expand Up @@ -76,13 +79,15 @@
33AFDFEE2B8D14C200AAB120 /* RNSentryFramesTrackerListenerTests.h */,
33AFDFF02B8D15E500AAB120 /* RNSentryDependencyContainerTests.m */,
33AFDFF22B8D15F600AAB120 /* RNSentryDependencyContainerTests.h */,
33958C682BFCF12600AD1FB6 /* RNSentryOnDrawReporterTests.m */,
);
path = RNSentryCocoaTesterTests;
sourceTree = "<group>";
};
33AFE0122B8F319000AAB120 /* RNSentry */ = {
isa = PBXGroup;
children = (
33958C672BFCEF5A00AD1FB6 /* RNSentryOnDrawReporter.h */,
33AFE0132B8F31AF00AAB120 /* RNSentryDependencyContainer.h */,
);
name = RNSentry;
Expand Down Expand Up @@ -198,6 +203,7 @@
files = (
33AFDFF12B8D15E500AAB120 /* RNSentryDependencyContainerTests.m in Sources */,
33F58AD02977037D008F60EA /* RNSentryTests.mm in Sources */,
33958C692BFCF12600AD1FB6 /* RNSentryOnDrawReporterTests.m in Sources */,
33AFDFED2B8D14B300AAB120 /* RNSentryFramesTrackerListenerTests.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#import <XCTest/XCTest.h>
#import "RNSentryOnDrawReporter.h"

@interface RNSentryOnDrawReporterTests : XCTestCase

@end

@implementation RNSentryOnDrawReporterTests

- (void)testRNSentryOnDrawReporterViewIsAvailableWhenUIKitIs
{
RNSentryOnDrawReporterView* view = [[RNSentryOnDrawReporterView alloc] init];
XCTAssertNotNil(view);
}

@end
23 changes: 23 additions & 0 deletions ios/RNSentryOnDrawReporter.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#import <Sentry/SentryDefines.h>

#if SENTRY_HAS_UIKIT

#import <UIKit/UIKit.h>
#import <React/RCTViewManager.h>
#import "RNSentryFramesTrackerListener.h"

@interface RNSentryOnDrawReporter : RCTViewManager

@end

@interface RNSentryOnDrawReporterView : UIView

@property (nonatomic, strong) RNSentryFramesTrackerListener* framesListener;
@property (nonatomic, copy) RCTBubblingEventBlock onDrawNextFrame;
@property (nonatomic) bool fullDisplay;
@property (nonatomic) bool initialDisplay;
@property (nonatomic, weak) RNSentryOnDrawReporter* delegate;

@end

#endif
19 changes: 2 additions & 17 deletions ios/RNSentryOnDrawReporter.m
Original file line number Diff line number Diff line change
@@ -1,24 +1,9 @@
#import "RNSentryOnDrawReporter.h"

#if SENTRY_HAS_UIKIT

#import <UIKit/UIKit.h>
#import <React/RCTViewManager.h>
#import "RNSentryFramesTrackerListener.h"
#import <Sentry/SentryDependencyContainer.h>

@interface RNSentryOnDrawReporter : RCTViewManager

@end

@interface RNSentryOnDrawReporterView : UIView

@property (nonatomic, strong) RNSentryFramesTrackerListener* framesListener;
@property (nonatomic, copy) RCTBubblingEventBlock onDrawNextFrame;
@property (nonatomic) bool fullDisplay;
@property (nonatomic) bool initialDisplay;
@property (nonatomic, weak) RNSentryOnDrawReporter* delegate;

@end

@implementation RNSentryOnDrawReporter

RCT_EXPORT_MODULE(RNSentryOnDrawReporter)
Expand Down

0 comments on commit 41f816a

Please sign in to comment.