Expose Native.EnableScopePersistence (Android) and Native.EnableCrashHandler (iOS)

Abierto
#5,767 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
55/100
Tipo de issue
Nueva funcionalidad
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
csharp
Área
backend

Línea de trabajo

Read src/Sentry/Platforms/Android/SentrySdk.cs and src/Sentry/Platforms/Cocoa/SentrySdk.cs, then locate the matching BindableNativeSentryOptions and Cocoa BindableSentryOptions entries. Forward both native settings during SDK initialization and document them on the native options pages; done when each option reaches its platform SDK and the documented behavior includes Cocoa watchdog tracking.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Feature Platform: Android Platform: iOS State: Needs Discussion

Users who want to limit what the native SDKs collect or write to disk on mobile have no way to reach two relevant native options from .NET. Both bindings already exist.

Android: EnableScopePersistence

sentry-java's PersistingScopeObserver writes the current scope (user, tags, extras, contexts, request, breadcrumbs, …) to <cache>/android/.scope-cache/ on every change. It's on by default (SentryOptions.enableScopePersistence) and only used to backfill ANR (ApplicationExitInfo) and tombstone events. Expose it as options.Native.EnableScopePersistence and forward it alongside the other options in InitSentryAndroidSdk.

iOS / Mac Catalyst: EnableCrashHandler

The Cocoa SDK's enableCrashHandler (default true, bound at ApiDefinition.cs as EnableCrashHandler) isn't forwarded. That leaves no supported way to turn off native crash reporting on iOS while keeping managed error capture. (Android can already do this with Native.EnableNdk, Native.EnableUncaughtExceptionHandler and Native.AnrEnabled.) Expose it as options.Native.EnableCrashHandler and forward it in InitSentryCocoaSdk. Note that disabling it also disables Cocoa's watchdog termination tracking.

Both need matching BindableNativeSentryOptions / Cocoa BindableSentryOptions entries, and docs on the native options pages.

Raised in #5733.

Lenguaje dominante
C#
Estrellas
775
Forks
262
Merge medio
1 d 16 h
PR fusionados (30 d)
118

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de getsentry/sentry-dotnet

Todos los issues de getsentry/sentry-dotnet

Issues similares

Más issues de C#

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.