From 748ff5789313f72fcc78dbcf99ff2f7647a6f810 Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Tue, 16 Sep 2025 18:26:43 -0400 Subject: [PATCH 01/21] fix: Generate and inject uuid to apk and upload proguard with that uuid --- src/Sentry/buildTransitive/Sentry.targets | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/src/Sentry/buildTransitive/Sentry.targets b/src/Sentry/buildTransitive/Sentry.targets index 653cc294c0..b63f1ba88b 100644 --- a/src/Sentry/buildTransitive/Sentry.targets +++ b/src/Sentry/buildTransitive/Sentry.targets @@ -18,6 +18,7 @@ Sentry.Attributes$(MSBuildProjectExtension.Replace('proj', '')) + $([System.Guid]::NewGuid()) $(SentrySetCommitReleaseOptions) --org $(SentryOrg) $(SentrySetCommitReleaseOptions) --project $(SentryProject) + $(SentryProguardOptions) --uuid "$(ProguardUuid)" + $(SentryProguardOptions) --app-id "$(ApplicationId)" + $(SentryProguardOptions) --version "$(ApplicationDisplayVersion)" + $(SentryProguardOptions) --version-code "$(ApplicationVersion)" + $(SentryProguardOptions.trim()) + $(SentryCLIUploadOptions) --org $(SentryOrg) $(SentryCLIUploadOptions) --project $(SentryProject) $(SentryCLIBaseCommand) debug-files upload $(SentryCLIDebugFilesUploadCommand) $(SentryCLIUploadOptions.Trim()) - $(SentryCLIBaseCommand) upload-proguard + $(SentryCLIBaseCommand) upload-proguard $(SentryProguardOptions) $(SentryCLIProGuardMappingUploadCommand) $(SentryCLIUploadOptions.Trim()) @@ -267,6 +274,16 @@ + + + + + <_Parameter1>io.sentry.proguard-uuid + $(ProguardUuid) + + + + From b4da8a3cdaa211e4cb75eeda2b5647364d9fbf5d Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Tue, 16 Sep 2025 19:11:21 -0400 Subject: [PATCH 02/21] Add android check before injecting uuid to apk --- src/Sentry/buildTransitive/Sentry.targets | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Sentry/buildTransitive/Sentry.targets b/src/Sentry/buildTransitive/Sentry.targets index b63f1ba88b..963e534dca 100644 --- a/src/Sentry/buildTransitive/Sentry.targets +++ b/src/Sentry/buildTransitive/Sentry.targets @@ -70,8 +70,7 @@ true + ">true @@ -274,7 +273,7 @@ - + From 833f58768f630add39d3a638772609c799a3489b Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Tue, 16 Sep 2025 19:18:11 -0400 Subject: [PATCH 03/21] Revert temporary change in sentry.targets --- src/Sentry/buildTransitive/Sentry.targets | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Sentry/buildTransitive/Sentry.targets b/src/Sentry/buildTransitive/Sentry.targets index 963e534dca..af4d2de7b8 100644 --- a/src/Sentry/buildTransitive/Sentry.targets +++ b/src/Sentry/buildTransitive/Sentry.targets @@ -70,7 +70,8 @@ true + and '$(MSBuildProjectName)' != 'Sentry' + and !$(MSBuildProjectName.StartsWith('Sentry.'))">true From 0324e899b907f332ff2d024625475b928215dd81 Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Tue, 16 Sep 2025 19:20:14 -0400 Subject: [PATCH 04/21] Update changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2cc59b8f81..532673f3ae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ - Fail when building Blazor WASM with Profiling. We don't support profiling in Blazor WebAssembly projects. ([#4512](https://github.com/getsentry/sentry-dotnet/pull/4512)) - Do not overwrite user IP if it is set manually in ASP.NET sdk ([#4513](https://github.com/getsentry/sentry-dotnet/pull/4513)) +- In MAUI Android apps, generate and inject uuid to Apk and upload Proguard to Sentry with the uuid ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) ## 5.15.0 From 5023e67782a06367f3375624b7cefd5fd47bb18e Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Wed, 17 Sep 2025 16:15:50 -0400 Subject: [PATCH 05/21] Add proper condition for Android uuid injection --- src/Sentry/buildTransitive/Sentry.targets | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Sentry/buildTransitive/Sentry.targets b/src/Sentry/buildTransitive/Sentry.targets index af4d2de7b8..c27d69334a 100644 --- a/src/Sentry/buildTransitive/Sentry.targets +++ b/src/Sentry/buildTransitive/Sentry.targets @@ -274,7 +274,11 @@ - + From b1aab6d02f8ede9519b9c6f22a2f31a8dccd4367 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20P=C3=B6lz?= <38893694+Flash0ver@users.noreply.github.com> Date: Thu, 18 Sep 2025 12:09:31 +0200 Subject: [PATCH 06/21] ci: update integration-test Action --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index df1d3c25f9..81ea8a7ebe 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -267,7 +267,7 @@ jobs: path: src - name: Integration test - uses: getsentry/github-workflows/sentry-cli/integration-test/@v2 + uses: getsentry/github-workflows/sentry-cli/integration-test/@0ee6d58acd5ca949358c3f62263a3c592689553e with: path: integration-test @@ -348,7 +348,7 @@ jobs: path: src - name: Test AOT - uses: getsentry/github-workflows/sentry-cli/integration-test/@v2 + uses: getsentry/github-workflows/sentry-cli/integration-test/@0ee6d58acd5ca949358c3f62263a3c592689553e env: RuntimeIdentifier: ${{ matrix.rid }} with: From 6fc81467078bf4f807a7798d70f0647ac30ef452 Mon Sep 17 00:00:00 2001 From: Alex Sohn <44201357+alexsohn1126@users.noreply.github.com> Date: Fri, 19 Sep 2025 11:24:47 -0400 Subject: [PATCH 07/21] Update CHANGELOG.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Stefan Pölz <38893694+Flash0ver@users.noreply.github.com> --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9ea50fc948..5816549768 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,7 @@ - Fail when building Blazor WASM with Profiling. We don't support profiling in Blazor WebAssembly projects. ([#4512](https://github.com/getsentry/sentry-dotnet/pull/4512)) - Do not overwrite user IP if it is set manually in ASP.NET sdk ([#4513](https://github.com/getsentry/sentry-dotnet/pull/4513)) -- In MAUI Android apps, generate and inject uuid to Apk and upload Proguard to Sentry with the uuid ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) +- In MAUI Android apps, generate and inject UUID to APK and upload Proguard to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) - Fix `SentryOptions.Native.SuppressSignalAborts` and `SuppressExcBadAccess` on iOS ([#4521](https://github.com/getsentry/sentry-dotnet/pull/4521)) ## 5.15.0 From 19db6202d4ef67e871b13a70e9143a798837bc15 Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Fri, 19 Sep 2025 12:12:08 -0400 Subject: [PATCH 08/21] Code Reviews applied --- CHANGELOG.md | 2 +- src/Sentry/buildTransitive/Sentry.targets | 16 ++++++---------- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5816549768..a8368ef131 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,7 @@ - Fail when building Blazor WASM with Profiling. We don't support profiling in Blazor WebAssembly projects. ([#4512](https://github.com/getsentry/sentry-dotnet/pull/4512)) - Do not overwrite user IP if it is set manually in ASP.NET sdk ([#4513](https://github.com/getsentry/sentry-dotnet/pull/4513)) -- In MAUI Android apps, generate and inject UUID to APK and upload Proguard to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) +- In MAUI Android apps, generate and inject UUID to APK and upload ProGuard mapping to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) - Fix `SentryOptions.Native.SuppressSignalAborts` and `SuppressExcBadAccess` on iOS ([#4521](https://github.com/getsentry/sentry-dotnet/pull/4521)) ## 5.15.0 diff --git a/src/Sentry/buildTransitive/Sentry.targets b/src/Sentry/buildTransitive/Sentry.targets index c27d69334a..3f4fe57f20 100644 --- a/src/Sentry/buildTransitive/Sentry.targets +++ b/src/Sentry/buildTransitive/Sentry.targets @@ -18,7 +18,7 @@ Sentry.Attributes$(MSBuildProjectExtension.Replace('proj', '')) - $([System.Guid]::NewGuid()) + $([System.Guid]::NewGuid()) $(SentrySetCommitReleaseOptions) --org $(SentryOrg) $(SentrySetCommitReleaseOptions) --project $(SentryProject) - $(SentryProguardOptions) --uuid "$(ProguardUuid)" - $(SentryProguardOptions) --app-id "$(ApplicationId)" - $(SentryProguardOptions) --version "$(ApplicationDisplayVersion)" - $(SentryProguardOptions) --version-code "$(ApplicationVersion)" - $(SentryProguardOptions.trim()) + <_SentryCLIProGuardOptions Condition="'$(SentryProGuardUUID)' != ''">$(_SentryCLIProGuardOptions) --uuid "$(SentryProGuardUUID)" + <_SentryCLIProGuardOptions Condition="'$(_SentryCLIProGuardOptions.Trim())' != ''">$(_SentryCLIProGuardOptions.Trim()) $(SentryCLIUploadOptions) --org $(SentryOrg) $(SentryCLIUploadOptions) --project $(SentryProject) $(SentryCLIBaseCommand) debug-files upload $(SentryCLIDebugFilesUploadCommand) $(SentryCLIUploadOptions.Trim()) - $(SentryCLIBaseCommand) upload-proguard $(SentryProguardOptions) + $(SentryCLIBaseCommand) upload-proguard $(_SentryCLIProGuardOptions) $(SentryCLIProGuardMappingUploadCommand) $(SentryCLIUploadOptions.Trim()) @@ -276,14 +273,13 @@ <_Parameter1>io.sentry.proguard-uuid - $(ProguardUuid) + $(SentryProGuardUUID) From 82356991173803d6a74046322f0404752687b6d5 Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Fri, 19 Sep 2025 13:09:50 -0400 Subject: [PATCH 09/21] Fix ProGuard capitalization --- src/Sentry/buildTransitive/Sentry.targets | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Sentry/buildTransitive/Sentry.targets b/src/Sentry/buildTransitive/Sentry.targets index 3f4fe57f20..76b4feb88e 100644 --- a/src/Sentry/buildTransitive/Sentry.targets +++ b/src/Sentry/buildTransitive/Sentry.targets @@ -69,7 +69,7 @@ We're explicitly skipping uploads for Sentry projects because they interfere with CLI integration test asserts. --> true @@ -274,7 +274,7 @@ + and '$(SentryUploadAndroidProGuardMapping)' == 'true'"> @@ -284,9 +284,9 @@ - - + + From 4b01f06580d2360b35e5ace9be19ddbb2b93f440 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 17 Sep 2025 12:31:30 +1200 Subject: [PATCH 10/21] chore(deps): update Cocoa SDK to v8.56.0 (#4528) --- CHANGELOG.md | 6 + modules/sentry-cocoa.properties | 2 +- scripts/generate-cocoa-bindings.ps1 | 3 - src/Sentry.Bindings.Cocoa/ApiDefinitions.cs | 13 +- .../PrivateApiDefinitions.cs | 7 - .../Sentry.Bindings.Cocoa.csproj | 2 + .../SwiftApiDefinitions.cs | 132 ++++++++++++++++++ .../SwiftStructsAndEnums.cs | 9 ++ 8 files changed, 161 insertions(+), 13 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a8368ef131..87428b6ec6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,12 @@ - In MAUI Android apps, generate and inject UUID to APK and upload ProGuard mapping to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) - Fix `SentryOptions.Native.SuppressSignalAborts` and `SuppressExcBadAccess` on iOS ([#4521](https://github.com/getsentry/sentry-dotnet/pull/4521)) +### Dependencies + +- Bump Cocoa SDK from v8.55.1 to v8.56.0 ([#4528](https://github.com/getsentry/sentry-dotnet/pull/4528)) + - [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8560) + - [diff](https://github.com/getsentry/sentry-cocoa/compare/8.55.1...8.56.0) + ## 5.15.0 ### Features diff --git a/modules/sentry-cocoa.properties b/modules/sentry-cocoa.properties index cb992f6d1a..d4dde9863e 100644 --- a/modules/sentry-cocoa.properties +++ b/modules/sentry-cocoa.properties @@ -1,2 +1,2 @@ -version = 8.55.1 +version = 8.56.0 repo = https://github.com/getsentry/sentry-cocoa diff --git a/scripts/generate-cocoa-bindings.ps1 b/scripts/generate-cocoa-bindings.ps1 index 04d44efeb6..eb1295808e 100644 --- a/scripts/generate-cocoa-bindings.ps1 +++ b/scripts/generate-cocoa-bindings.ps1 @@ -278,9 +278,6 @@ $Text = $Text -replace '([\[,] )iOS \(', '$1Introduced (PlatformName.iOS, ' # Make interface partial if we need to access private APIs. Other parts will be defined in PrivateApiDefinitions.cs $Text = $Text -replace '(?m)^interface SentryScope', 'partial $&' -# Prefix SentryBreadcrumb.Serialize and SentryScope.Serialize with new (since these hide the base method) -$Text = $Text -replace '(?m)(^\s*\/\/[^\r\n]*$\s*\[Export \("serialize"\)\]$\s*)(NSDictionary)', '${1}new $2' - $Text = $Text -replace '.*SentryEnvelope .*?[\s\S]*?\n\n', '' $Text = $Text -replace '.*typedef.*SentryOnAppStartMeasurementAvailable.*?[\s\S]*?\n\n', '' diff --git a/src/Sentry.Bindings.Cocoa/ApiDefinitions.cs b/src/Sentry.Bindings.Cocoa/ApiDefinitions.cs index 31997fdfd7..f33b1c6815 100644 --- a/src/Sentry.Bindings.Cocoa/ApiDefinitions.cs +++ b/src/Sentry.Bindings.Cocoa/ApiDefinitions.cs @@ -225,7 +225,7 @@ interface SentryBreadcrumb : SentrySerializable // -(NSDictionary * _Nonnull)serialize; [Export ("serialize")] - new NSDictionary Serialize(); + NSDictionary Serialize(); // -(BOOL)isEqualToBreadcrumb:(SentryBreadcrumb * _Nonnull)breadcrumb; [Export ("isEqualToBreadcrumb:")] @@ -930,6 +930,11 @@ interface SentrySpan : SentrySerializable [Abstract] [NullAllowed, Export ("baggageHttpHeader")] string BaggageHttpHeader { get; } + + // @required -(NSDictionary * _Nonnull)serialize; + [Abstract] + [Export ("serialize")] + NSDictionary Serialize(); } // @interface SentryHub : NSObject @@ -1494,6 +1499,10 @@ interface SentryOptions [Export ("attachScreenshot")] bool AttachScreenshot { get; set; } + // @property (nonatomic, strong) SentryViewScreenshotOptions * _Nonnull screenshot; + [Export ("screenshot", ArgumentSemantic.Strong)] + SentryViewScreenshotOptions Screenshot { get; set; } + // @property (assign, nonatomic) BOOL attachViewHierarchy; [Export ("attachViewHierarchy")] bool AttachViewHierarchy { get; set; } @@ -1864,7 +1873,7 @@ partial interface SentryScope : SentrySerializable // -(NSDictionary * _Nonnull)serialize; [Export ("serialize")] - new NSDictionary Serialize(); + NSDictionary Serialize(); // -(void)setContextValue:(NSDictionary * _Nonnull)value forKey:(NSString * _Nonnull)key __attribute__((swift_name("setContext(value:key:)"))); [Export ("setContextValue:forKey:")] diff --git a/src/Sentry.Bindings.Cocoa/PrivateApiDefinitions.cs b/src/Sentry.Bindings.Cocoa/PrivateApiDefinitions.cs index ccd5d1865d..55f59db3fe 100644 --- a/src/Sentry.Bindings.Cocoa/PrivateApiDefinitions.cs +++ b/src/Sentry.Bindings.Cocoa/PrivateApiDefinitions.cs @@ -17,13 +17,6 @@ partial interface SentryScope // The following types are type-forwarded in various public headers, but have no headers of their own. // Generate stub classes so the APIs that use them can still operate. -[Internal] -[DisableDefaultCtor] -[BaseType (typeof(NSObject))] -interface SentrySession -{ -} - [Internal] [DisableDefaultCtor] [BaseType (typeof(NSObject))] diff --git a/src/Sentry.Bindings.Cocoa/Sentry.Bindings.Cocoa.csproj b/src/Sentry.Bindings.Cocoa/Sentry.Bindings.Cocoa.csproj index 07bf94f189..98e6fde2d2 100644 --- a/src/Sentry.Bindings.Cocoa/Sentry.Bindings.Cocoa.csproj +++ b/src/Sentry.Bindings.Cocoa/Sentry.Bindings.Cocoa.csproj @@ -12,6 +12,8 @@ $([System.IO.File]::ReadAllText("$(MSBuildThisFileDirectory)../../modules/sentry-cocoa.properties")) $([System.Text.RegularExpressions.Regex]::Match($(SentryCocoaProperties), 'version\s*=\s*([^\s]+)').Groups[1].Value) $(SentryCocoaCache)Sentry-$(SentryCocoaVersion).xcframework + + $(NoWarn);CS0108 diff --git a/src/Sentry.Bindings.Cocoa/SwiftApiDefinitions.cs b/src/Sentry.Bindings.Cocoa/SwiftApiDefinitions.cs index 780be4d467..391360da15 100644 --- a/src/Sentry.Bindings.Cocoa/SwiftApiDefinitions.cs +++ b/src/Sentry.Bindings.Cocoa/SwiftApiDefinitions.cs @@ -556,6 +556,103 @@ interface SentrySDK void ClearLogger (); } +// @interface SentrySession : NSObject +[BaseType (typeof(NSObject), Name = "_TtC6Sentry13SentrySession")] +[DisableDefaultCtor] +[Internal] +interface SentrySession +{ + // -(instancetype _Nonnull)initWithReleaseName:(NSString * _Nonnull)releaseName distinctId:(NSString * _Nonnull)distinctId __attribute__((objc_designated_initializer)); + [Export ("initWithReleaseName:distinctId:")] + [DesignatedInitializer] + NativeHandle Constructor (string releaseName, string distinctId); + + // -(instancetype _Nullable)initWithJSONObject:(NSDictionary * _Nonnull)jsonObject __attribute__((objc_designated_initializer)); + [Export ("initWithJSONObject:")] + [DesignatedInitializer] + NativeHandle Constructor (NSDictionary jsonObject); + + // -(void)endSessionExitedWithTimestamp:(NSDate * _Nonnull)timestamp; + [Export ("endSessionExitedWithTimestamp:")] + void EndSessionExitedWithTimestamp (NSDate timestamp); + + // -(void)endSessionCrashedWithTimestamp:(NSDate * _Nonnull)timestamp; + [Export ("endSessionCrashedWithTimestamp:")] + void EndSessionCrashedWithTimestamp (NSDate timestamp); + + // -(void)endSessionAbnormalWithTimestamp:(NSDate * _Nonnull)timestamp; + [Export ("endSessionAbnormalWithTimestamp:")] + void EndSessionAbnormalWithTimestamp (NSDate timestamp); + + // -(void)incrementErrors; + [Export ("incrementErrors")] + void IncrementErrors (); + + // @property (readonly, copy, nonatomic) NSUUID * _Nonnull sessionId; + [Export ("sessionId", ArgumentSemantic.Copy)] + NSUuid SessionId { get; } + + // @property (readonly, copy, nonatomic) NSDate * _Nonnull started; + [Export ("started", ArgumentSemantic.Copy)] + NSDate Started { get; } + + // @property (readonly, nonatomic) enum SentrySessionStatus status; + [Export ("status")] + SentrySessionStatus Status { get; } + + // @property (nonatomic) NSUInteger errors; + [Export ("errors")] + nuint Errors { get; set; } + + // @property (readonly, nonatomic) NSUInteger sequence; + [Export ("sequence")] + nuint Sequence { get; } + + // @property (readonly, copy, nonatomic) NSString * _Nonnull distinctId; + [Export ("distinctId")] + string DistinctId { get; } + + // @property (readonly, nonatomic, strong) NSNumber * _Nullable flagInit; + [NullAllowed, Export ("flagInit", ArgumentSemantic.Strong)] + NSNumber FlagInit { get; } + + // @property (readonly, copy, nonatomic) NSDate * _Nullable timestamp; + [NullAllowed, Export ("timestamp", ArgumentSemantic.Copy)] + NSDate Timestamp { get; } + + // @property (readonly, nonatomic, strong) NSNumber * _Nullable duration; + [NullAllowed, Export ("duration", ArgumentSemantic.Strong)] + NSNumber Duration { get; } + + // @property (readonly, copy, nonatomic) NSString * _Nullable releaseName; + [NullAllowed, Export ("releaseName")] + string ReleaseName { get; } + + // @property (copy, nonatomic) NSString * _Nullable environment; + [NullAllowed, Export ("environment")] + string Environment { get; set; } + + // @property (nonatomic, strong) SentryUser * _Nullable user; + [NullAllowed, Export ("user", ArgumentSemantic.Strong)] + SentryUser User { get; set; } + + // @property (copy, nonatomic) NSString * _Nullable abnormalMechanism; + [NullAllowed, Export ("abnormalMechanism")] + string AbnormalMechanism { get; set; } + + // -(NSDictionary * _Nonnull)serialize __attribute__((warn_unused_result(""))); + [Export ("serialize")] + NSDictionary Serialize(); + + // -(void)setFlagInit; + [Export ("setFlagInit")] + void SetFlagInit (); + + // -(id _Nonnull)copyWithZone:(struct _NSZone * _Nullable)zone __attribute__((warn_unused_result(""))); + // [Export ("copyWithZone:")] + // unsafe NSObject CopyWithZone ([NullAllowed] _NSZone* zone); +} + // @interface SentryUserFeedback : NSObject [BaseType(typeof(NSObject))] [DisableDefaultCtor] @@ -750,6 +847,41 @@ interface SentryUserFeedbackWidgetConfiguration // IntPtr Constructor(); // } +// @interface SentryViewScreenshotOptions : NSObject +[BaseType (typeof(NSObject), Name = "_TtC6Sentry27SentryViewScreenshotOptions")] +[Internal] +interface SentryViewScreenshotOptions //: ISentryRedactOptions +{ + // @property (nonatomic) BOOL enableViewRendererV2; + [Export ("enableViewRendererV2")] + bool EnableViewRendererV2 { get; set; } + + // @property (nonatomic) BOOL enableFastViewRendering; + [Export ("enableFastViewRendering")] + bool EnableFastViewRendering { get; set; } + + // @property (nonatomic) BOOL maskAllImages; + [Export ("maskAllImages")] + bool MaskAllImages { get; set; } + + // @property (nonatomic) BOOL maskAllText; + [Export ("maskAllText")] + bool MaskAllText { get; set; } + + // @property (copy, nonatomic) NSArray * _Nonnull maskedViewClasses; + [Export ("maskedViewClasses", ArgumentSemantic.Copy)] + Class[] MaskedViewClasses { get; set; } + + // @property (copy, nonatomic) NSArray * _Nonnull unmaskedViewClasses; + [Export ("unmaskedViewClasses", ArgumentSemantic.Copy)] + Class[] UnmaskedViewClasses { get; set; } + + // -(instancetype _Nonnull)initWithEnableViewRendererV2:(BOOL)enableViewRendererV2 enableFastViewRendering:(BOOL)enableFastViewRendering maskAllText:(BOOL)maskAllText maskAllImages:(BOOL)maskAllImages maskedViewClasses:(NSArray * _Nonnull)maskedViewClasses unmaskedViewClasses:(NSArray * _Nonnull)unmaskedViewClasses __attribute__((objc_designated_initializer)); + [Export ("initWithEnableViewRendererV2:enableFastViewRendering:maskAllText:maskAllImages:maskedViewClasses:unmaskedViewClasses:")] + [DesignatedInitializer] + NativeHandle Constructor (bool enableViewRendererV2, bool enableFastViewRendering, bool maskAllText, bool maskAllImages, Class[] maskedViewClasses, Class[] unmaskedViewClasses); +} + // @protocol SentryViewScreenshotProvider [Protocol (Name = "_TtP6Sentry28SentryViewScreenshotProvider_")] [Model] diff --git a/src/Sentry.Bindings.Cocoa/SwiftStructsAndEnums.cs b/src/Sentry.Bindings.Cocoa/SwiftStructsAndEnums.cs index 806daffd87..1453151744 100644 --- a/src/Sentry.Bindings.Cocoa/SwiftStructsAndEnums.cs +++ b/src/Sentry.Bindings.Cocoa/SwiftStructsAndEnums.cs @@ -69,6 +69,15 @@ internal enum SentryRRWebEventType : long Custom = 5 } +[Native] +internal enum SentrySessionStatus : ulong +{ + Ok = 0, + Exited = 1, + Crashed = 2, + Abnormal = 3 +} + [Native] internal enum SentryTransactionNameSource : long { From 7b9b8714403bed6788c5cee09622f47cdf2031ea Mon Sep 17 00:00:00 2001 From: J-P Nurmi Date: Fri, 19 Sep 2025 11:41:48 +0200 Subject: [PATCH 11/21] ci: install Mono for Ubuntu (ARM64) (#4545) --- .github/actions/environment/action.yml | 10 +++++++++- .github/workflows/build.yml | 4 ++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/actions/environment/action.yml b/.github/actions/environment/action.yml index 6d1cf35f69..9e451a282e 100644 --- a/.github/actions/environment/action.yml +++ b/.github/actions/environment/action.yml @@ -67,7 +67,7 @@ runs: distribution: ${{ runner.os == 'Windows' && runner.arch == 'ARM64' && 'microsoft' || 'temurin' }} java-version: '11' - - name: Install Mono + - name: Install Mono (macOS) if: runner.os == 'macOS' shell: bash # Attempt to install Mono, allowing it to fail silently @@ -76,6 +76,14 @@ runs: brew install mono || true brew link --overwrite mono + - name: Install Mono (Ubuntu) + if: ${{ runner.os == 'Linux' && !matrix.container }} + shell: bash + run: | + sudo apt install -y mono-devel + # restore perms for actions/setup-dotnet + sudo chmod -R a+rw /usr/share/dotnet + - name: Install .NET SDK uses: actions/setup-dotnet@v4 with: diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 81ea8a7ebe..07a8ae9c2e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -19,7 +19,7 @@ jobs: fail-fast: false matrix: include: - - os: ubuntu-22.04 # Pin ubuntu to ensure mono is installed + - os: ubuntu-22.04 rid: linux-x64 - os: ubuntu-22.04-arm rid: linux-arm64 @@ -82,7 +82,7 @@ jobs: fail-fast: false matrix: include: - - os: ubuntu-22.04 # Pin ubuntu to ensure mono is installed + - os: ubuntu-22.04 rid: linux-x64 slnf: Sentry-CI-Build-Linux.slnf - os: ubuntu-22.04-arm From 866ceb411516dac28495f9a1f578d1916bf4c410 Mon Sep 17 00:00:00 2001 From: J-P Nurmi Date: Sat, 20 Sep 2025 00:42:32 +0200 Subject: [PATCH 12/21] chore(deps): bump coverlet.collector to avoid vulnerability warnings (#4547) --- test/Directory.Build.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/Directory.Build.props b/test/Directory.Build.props index 5c1a6a9d47..20b6c7ac79 100644 --- a/test/Directory.Build.props +++ b/test/Directory.Build.props @@ -65,7 +65,7 @@ - + From 2a6c61164bdec38c4e452736ac6e919db2e664d6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 20 Sep 2025 10:43:07 +1200 Subject: [PATCH 13/21] chore: update modules/sentry-native to 0.11.0 (#4542) Co-authored-by: GitHub --- CHANGELOG.md | 3 +++ modules/sentry-native | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 87428b6ec6..8a21a36e67 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,9 @@ - Bump Cocoa SDK from v8.55.1 to v8.56.0 ([#4528](https://github.com/getsentry/sentry-dotnet/pull/4528)) - [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8560) - [diff](https://github.com/getsentry/sentry-cocoa/compare/8.55.1...8.56.0) +- Bump Native SDK from v0.10.1 to v0.11.0 ([#4542](https://github.com/getsentry/sentry-dotnet/pull/4542)) + - [changelog](https://github.com/getsentry/sentry-native/blob/master/CHANGELOG.md#0110) + - [diff](https://github.com/getsentry/sentry-native/compare/0.10.1...0.11.0) ## 5.15.0 diff --git a/modules/sentry-native b/modules/sentry-native index 11f94efc64..3bd091313a 160000 --- a/modules/sentry-native +++ b/modules/sentry-native @@ -1 +1 @@ -Subproject commit 11f94efc64d55e90aef9456ce01716c846ae1732 +Subproject commit 3bd091313ae97be90be62696a2babe591a988eb8 From 4995dd61267eff851fef67c18fa9112e13eedf7c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 20 Sep 2025 10:43:57 +1200 Subject: [PATCH 14/21] chore: update scripts/update-cli.ps1 to 2.54.0 (#4541) Co-authored-by: GitHub Co-authored-by: James Crosswell --- CHANGELOG.md | 3 +++ Directory.Build.props | 2 +- src/Sentry/Sentry.csproj | 14 +++++++------- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8a21a36e67..276cd1d044 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,9 @@ - Bump Cocoa SDK from v8.55.1 to v8.56.0 ([#4528](https://github.com/getsentry/sentry-dotnet/pull/4528)) - [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8560) - [diff](https://github.com/getsentry/sentry-cocoa/compare/8.55.1...8.56.0) +- Bump CLI from v2.53.0 to v2.54.0 ([#4541](https://github.com/getsentry/sentry-dotnet/pull/4541)) + - [changelog](https://github.com/getsentry/sentry-cli/blob/master/CHANGELOG.md#2540) + - [diff](https://github.com/getsentry/sentry-cli/compare/2.53.0...2.54.0) - Bump Native SDK from v0.10.1 to v0.11.0 ([#4542](https://github.com/getsentry/sentry-dotnet/pull/4542)) - [changelog](https://github.com/getsentry/sentry-native/blob/master/CHANGELOG.md#0110) - [diff](https://github.com/getsentry/sentry-native/compare/0.10.1...0.11.0) diff --git a/Directory.Build.props b/Directory.Build.props index af86671bdf..87bd9b96f4 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -86,7 +86,7 @@ - 2.53.0 + 2.54.0 $(MSBuildThisFileDirectory)tools\sentry-cli\$(SentryCLIVersion)\ diff --git a/src/Sentry/Sentry.csproj b/src/Sentry/Sentry.csproj index f00de450ff..c560abff9b 100644 --- a/src/Sentry/Sentry.csproj +++ b/src/Sentry/Sentry.csproj @@ -113,13 +113,13 @@ <_OSArchitecture>$([System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture) - - - - - - - + + + + + + + From d1505f1f1030d5eeb7af646da924f013b97d1e86 Mon Sep 17 00:00:00 2001 From: getsentry-bot Date: Fri, 19 Sep 2025 23:17:34 +0000 Subject: [PATCH 15/21] release: 5.15.1 --- CHANGELOG.md | 2 +- Directory.Build.props | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 276cd1d044..7e493a8710 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## Unreleased +## 5.15.1 ### Fixes diff --git a/Directory.Build.props b/Directory.Build.props index 87bd9b96f4..a74738d5cd 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -1,7 +1,7 @@ - 5.15.0 + 5.15.1 13 true true From 1407ce300ace9d1ddad5591842e89b280fef85be Mon Sep 17 00:00:00 2001 From: James Crosswell Date: Sun, 21 Sep 2025 10:23:53 +1200 Subject: [PATCH 16/21] chore: Disable flaky Profiler_AfterTimeout_Stops in CI (#4549) Resolves #4548 - https://github.com/getsentry/sentry-dotnet/issues/4548 #skip-changelog --- test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs b/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs index a160f3727d..c4e5ae71c3 100644 --- a/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs +++ b/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs @@ -166,7 +166,7 @@ public void Profiler_MultipleProfiles_Works(int startTimeoutSeconds) [SkippableFact] public async Task Profiler_AfterTimeout_Stops() { - Skip.If(TestEnvironment.IsGitHubActions && RuntimeInformation.IsOSPlatform(OSPlatform.Windows), "Flaky in CI on Windows"); + Skip.If(TestEnvironment.IsGitHubActions, "Flaky in CI"); SampleProfilerSession? session = null; SkipIfFailsInCI(() => session = SampleProfilerSession.StartNew(_testOutputLogger)); From ceccf5214afb23c7d63961bb13f00a2eef873ad9 Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Tue, 16 Sep 2025 19:20:14 -0400 Subject: [PATCH 17/21] Update changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7e493a8710..8b1b178170 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,7 @@ - Bump Native SDK from v0.10.1 to v0.11.0 ([#4542](https://github.com/getsentry/sentry-dotnet/pull/4542)) - [changelog](https://github.com/getsentry/sentry-native/blob/master/CHANGELOG.md#0110) - [diff](https://github.com/getsentry/sentry-native/compare/0.10.1...0.11.0) +- In MAUI Android apps, generate and inject uuid to Apk and upload Proguard to Sentry with the uuid ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) ## 5.15.0 From 10f98690db7a7eb9c2f4de9e8d314b97586d47a3 Mon Sep 17 00:00:00 2001 From: Alex Sohn <44201357+alexsohn1126@users.noreply.github.com> Date: Fri, 19 Sep 2025 11:24:47 -0400 Subject: [PATCH 18/21] Update CHANGELOG.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Stefan Pölz <38893694+Flash0ver@users.noreply.github.com> --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8b1b178170..b5c47cbfc6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ - Fail when building Blazor WASM with Profiling. We don't support profiling in Blazor WebAssembly projects. ([#4512](https://github.com/getsentry/sentry-dotnet/pull/4512)) - Do not overwrite user IP if it is set manually in ASP.NET sdk ([#4513](https://github.com/getsentry/sentry-dotnet/pull/4513)) - In MAUI Android apps, generate and inject UUID to APK and upload ProGuard mapping to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) +- In MAUI Android apps, generate and inject UUID to APK and upload Proguard to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) - Fix `SentryOptions.Native.SuppressSignalAborts` and `SuppressExcBadAccess` on iOS ([#4521](https://github.com/getsentry/sentry-dotnet/pull/4521)) ### Dependencies From 0ac6e783c16d583e146faa6134cc0516b14d14bc Mon Sep 17 00:00:00 2001 From: Alex Sohn Date: Mon, 22 Sep 2025 09:37:58 -0400 Subject: [PATCH 19/21] Update changelog.md --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b5c47cbfc6..a2bbc57e84 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## Unreleased + +### Fixes + +- In MAUI Android apps, generate and inject UUID to APK and upload ProGuard mapping to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) + ## 5.15.1 ### Fixes From 3df1fc412234cae197a95a6edf9c9cbb986e7368 Mon Sep 17 00:00:00 2001 From: Alex Sohn <44201357+alexsohn1126@users.noreply.github.com> Date: Mon, 22 Sep 2025 09:44:32 -0400 Subject: [PATCH 20/21] Update CHANGELOG.md --- CHANGELOG.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 78070a7b1b..baadd4e5e7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,8 +12,6 @@ - Fail when building Blazor WASM with Profiling. We don't support profiling in Blazor WebAssembly projects. ([#4512](https://github.com/getsentry/sentry-dotnet/pull/4512)) - Do not overwrite user IP if it is set manually in ASP.NET sdk ([#4513](https://github.com/getsentry/sentry-dotnet/pull/4513)) -- In MAUI Android apps, generate and inject UUID to APK and upload ProGuard mapping to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) -- In MAUI Android apps, generate and inject UUID to APK and upload Proguard to Sentry with the UUID ([#4532](https://github.com/getsentry/sentry-dotnet/pull/4532)) - Fix `SentryOptions.Native.SuppressSignalAborts` and `SuppressExcBadAccess` on iOS ([#4521](https://github.com/getsentry/sentry-dotnet/pull/4521)) ### Dependencies From 30e19d454fdac398d8bf1b265c81ec0de4c3c2b8 Mon Sep 17 00:00:00 2001 From: Alex Sohn <44201357+alexsohn1126@users.noreply.github.com> Date: Mon, 22 Sep 2025 09:47:01 -0400 Subject: [PATCH 21/21] Update build.yml --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 07a8ae9c2e..f54403af15 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -267,7 +267,7 @@ jobs: path: src - name: Integration test - uses: getsentry/github-workflows/sentry-cli/integration-test/@0ee6d58acd5ca949358c3f62263a3c592689553e + uses: getsentry/github-workflows/sentry-cli/integration-test/@a5e409bd5bad4c295201cdcfe862b17c50b29ab7 # v2.14.1 with: path: integration-test @@ -348,7 +348,7 @@ jobs: path: src - name: Test AOT - uses: getsentry/github-workflows/sentry-cli/integration-test/@0ee6d58acd5ca949358c3f62263a3c592689553e + uses: getsentry/github-workflows/sentry-cli/integration-test/@a5e409bd5bad4c295201cdcfe862b17c50b29ab7 # v2.14.1 env: RuntimeIdentifier: ${{ matrix.rid }} with: