Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ref: Remove SentryPrivate #3623

Merged
merged 78 commits into from
Mar 4, 2024
Merged
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
90184c0
Update project.pbxproj
brustolin Feb 8, 2024
64510cd
Fix header
brustolin Feb 8, 2024
d2cf616
Format code
getsentry-bot Feb 8, 2024
e1662f7
Update SentrySwift.h
brustolin Feb 8, 2024
24afb92
Format code
getsentry-bot Feb 8, 2024
f5735ef
Fixing tests
brustolin Feb 8, 2024
16efe5a
Merge branch 'fix/no-sentryprivate-for-self-build' of github.com:gets…
brustolin Feb 8, 2024
ac7fdfe
Format code
getsentry-bot Feb 8, 2024
a9faa57
Remove SentryPrivate from cocoapod
brustolin Feb 9, 2024
a4b5db3
Update pod-lib-lint.sh
brustolin Feb 9, 2024
01b0ce9
Update SentrySwift.h
brustolin Feb 9, 2024
cf0cead
Format code
getsentry-bot Feb 9, 2024
704b1ec
Update CHANGELOG.md
brustolin Feb 9, 2024
818ff21
Update CHANGELOG.md
brustolin Feb 12, 2024
f45f7c3
Merge branch 'main' into fix/no-sentryprivate-for-self-build
brustolin Feb 16, 2024
b4897d8
Pre compile framework for SPM
brustolin Feb 23, 2024
7908b73
Merge branch 'main' into fix/no-sentryprivate-for-self-build
brustolin Feb 23, 2024
9f73fc0
Merge branch 'main' into fix/no-sentryprivate-for-self-build
brustolin Feb 23, 2024
13036b9
Merge branch 'fix/no-sentryprivate-for-self-build' of github.com:gets…
brustolin Feb 23, 2024
87cb649
Update CHANGELOG.md
brustolin Feb 23, 2024
afeeedc
fix carthage
brustolin Feb 23, 2024
681437a
Update build.yml
brustolin Feb 23, 2024
ab970ca
Update build.yml
brustolin Feb 23, 2024
33ea8e9
Update build.yml
brustolin Feb 23, 2024
c081906
Update build.yml
brustolin Feb 23, 2024
e5d1d40
Merge branch 'main' into fix/no-sentryprivate-for-self-build
brustolin Feb 23, 2024
a6c8e13
remove perf
brustolin Feb 23, 2024
69504fe
Update release.yml
brustolin Feb 23, 2024
c92f2bf
Merge branch 'chore/fix-release-workflow' into intermediate/8.22.0
brustolin Feb 23, 2024
0acb870
Cache xcframework
brustolin Feb 26, 2024
e9f9444
Merge branch 'fix/no-sentryprivate-for-self-build' into intermediate/…
brustolin Feb 26, 2024
55e1143
Update Package.swift framework SHA
getsentry-bot Feb 26, 2024
70c0ecc
Update build.yml
brustolin Feb 26, 2024
ae9890e
Update release.yml
brustolin Feb 26, 2024
5065071
Update build.yml
brustolin Feb 26, 2024
058ccb3
Update Package.swift framework SHA
getsentry-bot Feb 26, 2024
a3b844d
Update Package.swift framework SHA
getsentry-bot Feb 26, 2024
4b1653e
using artefact
brustolin Feb 26, 2024
c581e28
Merge branch 'intermediate/8.22.0' of github.com:getsentry/sentry-coc…
brustolin Feb 26, 2024
d0afa59
Update xcframework-generated-run.sh
brustolin Feb 26, 2024
a6246e3
Update build.yml
brustolin Feb 26, 2024
2c4323f
Update Package.swift framework SHA
getsentry-bot Feb 26, 2024
3290d91
fixing artefact check
brustolin Feb 26, 2024
2c0aaf1
Merge branch 'intermediate/8.22.0' of github.com:getsentry/sentry-coc…
brustolin Feb 26, 2024
7cfe9a4
Update release.yml
brustolin Feb 26, 2024
5c89a2b
Update bump.sh
brustolin Feb 26, 2024
ebef537
Update update-package-sha.sh
brustolin Feb 26, 2024
dc24d43
Update update-package-sha.sh
brustolin Feb 26, 2024
f05bae5
Update update-package-sha.sh
brustolin Feb 26, 2024
6c7d447
Merge branch 'main' into intermediate/8.22.0
brustolin Feb 26, 2024
f2369e9
Update update-package-sha.sh
brustolin Feb 26, 2024
aa2e765
SwiftUI too
brustolin Feb 26, 2024
914d069
Apply suggestions from code review
brustolin Feb 26, 2024
c8d6e0a
Merge branch 'fix/no-sentryprivate-for-self-build' of github.com:gets…
brustolin Feb 26, 2024
a67aab7
restore perf tests
brustolin Feb 26, 2024
2bd640f
format
brustolin Feb 26, 2024
2f1a880
use a file for runid
brustolin Feb 27, 2024
820b575
No Carthage
brustolin Feb 27, 2024
56eac9c
Create build-xcframework.sh
brustolin Feb 27, 2024
0cbc391
Format code
getsentry-bot Feb 27, 2024
890bdd2
format
brustolin Feb 27, 2024
f420340
Merge branch 'fix/no-sentryprivate-for-self-build' of github.com:gets…
brustolin Feb 27, 2024
c8e6b24
Update AppDelegate.swift
brustolin Feb 27, 2024
630de64
Make pod works
brustolin Feb 28, 2024
05aeccf
Merge branch 'main' into fix/no-sentryprivate-for-self-build
brustolin Feb 28, 2024
335c1d0
Fix SentrySwiftUI for pods
brustolin Feb 28, 2024
49babe4
Merge branch 'fix/no-sentryprivate-for-self-build' of github.com:gets…
brustolin Feb 28, 2024
0a6d52b
fixing test
brustolin Feb 28, 2024
92a52d4
Update project.pbxproj
brustolin Feb 28, 2024
524355d
more fixes and enabling more ci
brustolin Feb 28, 2024
5f28a38
SPM validation
brustolin Feb 28, 2024
88822d6
Update build.yml
brustolin Feb 28, 2024
a9a593f
Update build.yml
brustolin Feb 29, 2024
574d762
Apply suggestions from code review
brustolin Mar 1, 2024
6d245ba
Apply suggestions from code review
brustolin Mar 1, 2024
e20f1a5
Update CHANGELOG.md
brustolin Mar 1, 2024
177f4ff
Merge branch 'main' into fix/no-sentryprivate-for-self-build
brustolin Mar 4, 2024
5f46b57
Update CHANGELOG.md
brustolin Mar 4, 2024
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
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,4 @@ jobs:
- run: ./scripts/ci-select-xcode.sh
- run: pod repo update
- name: Validate HybridPod Podspec
run: pod lib lint ./Tests/HybridSDKTest/HybridPod.podspec --allow-warnings --verbose --platforms=ios "--include-podspecs={SentryPrivate.podspec,Sentry.podspec}"
run: pod lib lint ./Tests/HybridSDKTest/HybridPod.podspec --allow-warnings --verbose --platforms=ios "--include-podspecs={Sentry.podspec}"
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
### Improvements

- Cache installationID async to avoid file IO on the main thread when starting the SDK (#3601)
- Remove SentryPrivate from Carthage and self build (#3623)
brustolin marked this conversation as resolved.
Show resolved Hide resolved

### Fixes

Expand Down
5 changes: 2 additions & 3 deletions Sentry.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -27,19 +27,18 @@ Pod::Spec.new do |s|
}

s.default_subspecs = ['Core']
s.dependency "SentryPrivate", "8.20.0"

s.subspec 'Core' do |sp|
sp.source_files = "Sources/Sentry/**/*.{h,hpp,m,mm,c,cpp}",
"Sources/SentryCrash/**/*.{h,hpp,m,mm,c,cpp}", "Sources/Swift/Sentry.swift"
"Sources/SentryCrash/**/*.{h,hpp,m,mm,c,cpp}", "Sources/Swift/**/*.{swift,h,hpp,m,mm,c,cpp}"
sp.public_header_files =
"Sources/Sentry/Public/*.h"
sp.resource = "Sources/Resources/PrivacyInfo.xcprivacy"
end

s.subspec 'HybridSDK' do |sp|
sp.source_files = "Sources/Sentry/**/*.{h,hpp,m,mm,c,cpp}",
"Sources/SentryCrash/**/*.{h,hpp,m,mm,c,cpp}", "Sources/Swift/Sentry.swift"
"Sources/SentryCrash/**/*.{h,hpp,m,mm,c,cpp}", "Sources/Swift/**/*.{swift,h,hpp,m,mm,c,cpp}"

sp.public_header_files =
"Sources/Sentry/Public/*.h", "Sources/Sentry/include/HybridPublic/*.h"
Expand Down
354 changes: 10 additions & 344 deletions Sentry.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions SentryPrivate.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ Pod::Spec.new do |s|
s.source = { :git => "https://github.com/getsentry/sentry-cocoa.git",
:tag => s.version.to_s }
s.social_media_url = 'https://getsentry.com/'
s.deprecated = true

s.description = <<-DESC
Not for public use.
Expand Down
4 changes: 2 additions & 2 deletions Sources/Sentry/SentryCoreDataTracker.m
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
#import "SentryPredicateDescriptor.h"
#import "SentrySDK+Private.h"
#import "SentryScope+Private.h"
#import "SentrySpanProtocol.h"
@import SentryPrivate;
#import "SentrySpan.h"
#import "SentrySpanProtocol.h"
#import "SentryStacktrace.h"
#import "SentrySwift.h"
#import "SentryThreadInspector.h"
#import "SentryTraceOrigins.h"

Expand Down
2 changes: 1 addition & 1 deletion Sources/Sentry/SentryNetworkTracker.m
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
#import "SentryScope+Private.h"
#import "SentrySerialization.h"
#import "SentryStacktrace.h"
#import "SentrySwift.h"
#import "SentryThread.h"
#import "SentryThreadInspector.h"
#import "SentryTraceContext.h"
Expand All @@ -25,7 +26,6 @@
#import "SentryTracer.h"
#import "SentryUser.h"
#import <objc/runtime.h>
@import SentryPrivate;

/**
* WARNING: We had issues in the past with this code on older iOS versions. We don't run unit tests
Expand Down
2 changes: 1 addition & 1 deletion Sources/Sentry/SentryTracer.m
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#import "SentrySpanContext+Private.h"
#import "SentrySpanContext.h"
#import "SentrySpanId.h"
#import "SentrySwift.h"
#import "SentryThreadWrapper.h"
#import "SentryTime.h"
#import "SentryTraceContext.h"
Expand All @@ -28,7 +29,6 @@
#import <SentryDispatchQueueWrapper.h>
#import <SentryMeasurementValue.h>
#import <SentrySpanOperations.h>
@import SentryPrivate;

#if SENTRY_TARGET_PROFILING_SUPPORTED
# import "SentryProfiledTracerConcurrency.h"
Expand Down
2 changes: 1 addition & 1 deletion Sources/Sentry/SentryUIApplication.m
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#import "SentryUIApplication.h"
#import "SentryDependencyContainer.h"
#import "SentryDispatchQueueWrapper.h"
@import SentryPrivate;
#import "SentryNSNotificationCenterWrapper.h"
#import "SentrySwift.h"

#if SENTRY_HAS_UIKIT

Expand Down
3 changes: 1 addition & 2 deletions Sources/Sentry/SentryViewHierarchy.m
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@
# import "SentryDependencyContainer.h"
# import "SentryDispatchQueueWrapper.h"
# import "SentryLog.h"
# import "SentrySwift.h"
# import "SentryUIApplication.h"
# import <UIKit/UIKit.h>

@import SentryPrivate;

static int
writeJSONDataToFile(const char *const data, const int length, void *const userData)
{
Expand Down
6 changes: 6 additions & 0 deletions Sources/Sentry/include/SentrySwift.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
#ifndef SentrySwift_h
#define SentrySwift_h

#if SWIFT_PACKAGE
@import SentryPrivate;
#elif __has_include("Sentry-Swift.h")
# import "Sentry-Swift.h"
#else
# import "Sentry/Sentry-Swift.h"
#endif
brustolin marked this conversation as resolved.
Show resolved Hide resolved

#endif
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#if os(iOS) || os(macOS)
import SentryPrivate
import XCTest

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -165,23 +165,23 @@ class TestMXDiagnosticPayload: MXDiagnosticPayload {
@available(watchOS, unavailable)
class SentryMXManagerTestDelegate: SentryMXManagerDelegate {

var crashInvocations = Invocations<(diagnostic: MXCrashDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveCrashDiagnostic(_ diagnostic: MXCrashDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
var crashInvocations = Invocations<(diagnostic: MXCrashDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveCrashDiagnostic(_ diagnostic: MXCrashDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
crashInvocations.record((diagnostic, callStackTree, timeStampBegin, timeStampEnd))
}

var diskWriteExceptionInvocations = Invocations<(diagnostic: MXDiskWriteExceptionDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveDiskWriteExceptionDiagnostic(_ diagnostic: MXDiskWriteExceptionDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
var diskWriteExceptionInvocations = Invocations<(diagnostic: MXDiskWriteExceptionDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveDiskWriteExceptionDiagnostic(_ diagnostic: MXDiskWriteExceptionDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
diskWriteExceptionInvocations.record((diagnostic, callStackTree, timeStampBegin, timeStampEnd))
}

var cpuExceptionInvocations = Invocations<(diagnostic: MXCPUExceptionDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveCpuExceptionDiagnostic(_ diagnostic: MXCPUExceptionDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
var cpuExceptionInvocations = Invocations<(diagnostic: MXCPUExceptionDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveCpuExceptionDiagnostic(_ diagnostic: MXCPUExceptionDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
cpuExceptionInvocations.record((diagnostic, callStackTree, timeStampBegin, timeStampEnd))
}

var hangDiagnosticInvocations = Invocations<(diagnostic: MXHangDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveHangDiagnostic(_ diagnostic: MXHangDiagnostic, callStackTree: SentryPrivate.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
var hangDiagnosticInvocations = Invocations<(diagnostic: MXHangDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date)>()
func didReceiveHangDiagnostic(_ diagnostic: MXHangDiagnostic, callStackTree: Sentry.SentryMXCallStackTree, timeStampBegin: Date, timeStampEnd: Date) {
hangDiagnosticInvocations.record((diagnostic, callStackTree, timeStampBegin, timeStampEnd))
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Sentry
import SentryPrivate
import SentryTestUtils
import XCTest

Expand Down
31 changes: 15 additions & 16 deletions Tests/SentryTests/SentryTests-Bridging-Header.h
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,18 @@
#import "SentrySdkInfo.h"
#import "SentrySwiftAsyncIntegration.h"

#import "Sentry/Sentry-Swift.h"
#import "SentryBinaryImageCache+Private.h"
#import "SentryCrashBinaryImageCache.h"
#import "SentryDispatchFactory.h"
#import "SentryDispatchSourceWrapper.h"
#import "SentryEnvelopeAttachmentHeader.h"
#import "SentryExtraContextProvider.h"
#import "SentryMeasurementValue.h"
#import "SentryNSProcessInfoWrapper.h"
#import "SentryPerformanceTracker+Testing.h"
#import "SentryPropagationContext.h"
#import "SentrySampleDecision+Private.h"
#import "SentrySerialization.h"
#import "SentrySession+Private.h"
#import "SentrySessionTracker.h"
Expand All @@ -186,9 +198,11 @@
#import "SentryThreadInspector.h"
#import "SentryThreadWrapper.h"
#import "SentryTime.h"
#import "SentryTimeToDisplayTracker.h"
#import "SentryTraceContext.h"
#import "SentryTracer+Private.h"
#import "SentryTracer+Test.h"
#import "SentryTracerConfiguration.h"
#import "SentryTransaction.h"
#import "SentryTransactionContext+Private.h"
#import "SentryTransport.h"
Expand All @@ -204,20 +218,5 @@
#import "TestNSURLRequestBuilder.h"
#import "TestSentryCrashWrapper.h"
#import "TestSentrySpan.h"
#import "URLSessionTaskMock.h"
@import SentryPrivate;
#import "SentryBinaryImageCache+Private.h"
#import "SentryCrashBinaryImageCache.h"
#import "SentryDispatchFactory.h"
#import "SentryDispatchSourceWrapper.h"
#import "SentryEnvelopeAttachmentHeader.h"
#import "SentryExtraContextProvider.h"
#import "SentryMeasurementValue.h"
#import "SentryNSProcessInfoWrapper.h"
#import "SentryPerformanceTracker+Testing.h"
#import "SentryPropagationContext.h"
#import "SentrySampleDecision+Private.h"
#import "SentrySpanOperations.h"
#import "SentryTimeToDisplayTracker.h"
#import "SentryTracerConfiguration.h"
#import "TestSentryViewHierarchy.h"
#import "URLSessionTaskMock.h"
1 change: 0 additions & 1 deletion Tests/SentryTests/UrlSanitizedTests.swift
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Foundation
import SentryPrivate
import XCTest

class UrlSanitizedTests: XCTestCase {
Expand Down
6 changes: 3 additions & 3 deletions scripts/pod-lib-lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ EXTRA_ARGS=""
case $POD_SPEC in

"Sentry")
INCLUDE_POD_SPECS="--include-podspecs=SentryPrivate.podspec"
INCLUDE_POD_SPECS=""
;;

"SentrySwiftUI")
INCLUDE_POD_SPECS="--include-podspecs={Sentry.podspec,SentryPrivate.podspec}"
INCLUDE_POD_SPECS="--include-podspecs=Sentry.podspec"
;;

*)
Expand All @@ -33,4 +33,4 @@ case $LIBRARY_TYPE in
;;
esac

pod lib lint --verbose --platforms="$PLATFORM" "$POD_SPEC".podspec "$INCLUDE_POD_SPECS" $EXTRA_ARGS
pod lib lint --verbose --platforms="$PLATFORM" "$POD_SPEC".podspec $INCLUDE_POD_SPECS $EXTRA_ARGS
Loading