From 25c1f068d11ace6211f92c95bee3e4fb0514f881 Mon Sep 17 00:00:00 2001 From: GitHub Date: Thu, 22 Oct 2026 03:01:17 +0000 Subject: [PATCH 1/2] chore: update modules/sentry-cocoa to 9.31.0 --- modules/sentry-cocoa | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/sentry-cocoa b/modules/sentry-cocoa index 4bb2282661..2f64c77f77 160000 --- a/modules/sentry-cocoa +++ b/modules/sentry-cocoa @@ -1 +1 @@ -Subproject commit 4bb2282661ee6ca2212aa01d19a1214394cd3c45 +Subproject commit 2f64c77f77514acd01780d1aac86ae75b7fccd04 From 2bd5cc68ecd5f2d2aa8ae01b47a0da718b41e7d1 Mon Sep 17 00:00:00 2001 From: Ricardo Colombo Oliveira Date: Thu, 22 Oct 2026 14:51:13 +0200 Subject: [PATCH 2/2] chore: regenerate Cocoa bindings for 9.31.0 Cocoa 9.31.0 adds SentryObjCExperimentalOptions.metrickit, which returns SentryObjCMetricKitOptions. That type isn't in the patch script's KeepInterfaces list, so the regenerated bindings failed to compile with CS0246. .NET doesn't expose MetricKit, so drop the property alongside the other option properties that reference types we don't bind. The rest is Objective Sharpie output: serializeScope: and serializeDebugMeta: on the internal serializer API, and the SentryObjCMetricKitHangReportingMode enum. Co-Authored-By: Claude Opus 5.5 --- scripts/patch-cocoa-bindings.cs | 2 ++ src/Sentry.Bindings.Cocoa/ApiDefinition.cs | 9 +++++++++ src/Sentry.Bindings.Cocoa/StructsAndEnums.cs | 7 +++++++ 3 files changed, 18 insertions(+) diff --git a/scripts/patch-cocoa-bindings.cs b/scripts/patch-cocoa-bindings.cs index f9d156ddff..2afa6c9e40 100644 --- a/scripts/patch-cocoa-bindings.cs +++ b/scripts/patch-cocoa-bindings.cs @@ -83,6 +83,8 @@ .RemoveProperty("SentryObjCOptions", "BeforeSendWithHint") .RemoveProperty("SentryObjCOptions", "BeforeBreadcrumbWithHint") .RemoveProperty("SentryObjCOptions", "ConfigureProfiling") + // Experimental MetricKit options; bind SentryObjCMetricKitOptions too if .NET ever exposes MetricKit. + .RemoveProperty("SentryObjCExperimentalOptions", "Metrickit") // SentryObjCSDK is both the public entry point and the hybrid-SDK gateway (via `internal`). // Keep the public members the .NET SDK calls plus the `internal` accessor; drop the rest, whose // signatures reference SentryObjC* types we don't whitelist. diff --git a/src/Sentry.Bindings.Cocoa/ApiDefinition.cs b/src/Sentry.Bindings.Cocoa/ApiDefinition.cs index fb657dff8f..cf57715f92 100644 --- a/src/Sentry.Bindings.Cocoa/ApiDefinition.cs +++ b/src/Sentry.Bindings.Cocoa/ApiDefinition.cs @@ -1271,6 +1271,7 @@ interface SentryObjCTraceContext [Internal] interface SentryObjCExperimentalOptions { + // @property (nonatomic) BOOL enableUnhandledCPPExceptionsV2; [Export("enableUnhandledCPPExceptionsV2")] bool EnableUnhandledCPPExceptionsV2 { get; set; } @@ -1805,6 +1806,14 @@ interface SentryObjCInternalSdkApi [Internal] interface SentryObjCInternalSerializerApi { + // -(NSDictionary * _Nonnull)serializeScope:(SentryObjCScope * _Nonnull)scope; + [Export("serializeScope:")] + NSDictionary SerializeScope(SentryObjCScope scope); + + // -(NSDictionary * _Nonnull)serializeDebugMeta:(SentryObjCDebugMeta * _Nonnull)debugMeta; + [Export("serializeDebugMeta:")] + NSDictionary SerializeDebugMeta(SentryObjCDebugMeta debugMeta); + // -(NSDictionary * _Nonnull)serializeEvent:(SentryObjCEvent * _Nonnull)event; [Export("serializeEvent:")] NSDictionary SerializeEvent(SentryObjCEvent @event); diff --git a/src/Sentry.Bindings.Cocoa/StructsAndEnums.cs b/src/Sentry.Bindings.Cocoa/StructsAndEnums.cs index f974ee79a4..6954c0e143 100644 --- a/src/Sentry.Bindings.Cocoa/StructsAndEnums.cs +++ b/src/Sentry.Bindings.Cocoa/StructsAndEnums.cs @@ -121,6 +121,13 @@ internal enum SentryObjCRedactRegionType : long RedactSwiftUI } +[Native] +internal enum SentryObjCMetricKitHangReportingMode : long +{ + Legacy = 0, + FlamegraphAttachment = 1 +} + [Native] internal enum SentryObjCSwizzleMode : long {