Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

### Fixes

- The configuration window's tooltips and help boxes and the option docs describe the SDK's defaults and requirements correctly: `Auto Set UserName` is disabled by default, `Attach Screenshots` also attaches screenshots to events on background threads, `Org Slug` is required unless the Auth Token is an organization token, `Scene Traces` has no Unity version requirement, and `IosWatchdogTerminationIntegrationEnabled` turns on reporting of watchdog terminations on iOS. ([#2933](https://github.com/getsentry/sentry-unity/pull/2933))
- The SDK no longer throws a `NullReferenceException` during startup on Android and iOS when it can't load its options, for example when the configuration lives in an OBB file that isn't available yet. ([#2931](https://github.com/getsentry/sentry-unity/pull/2931))
- Setting `FilterBadGatewayExceptions` to `false` now takes effect when initializing the SDK in code with `SentrySdk.Init`. ([#2930](https://github.com/getsentry/sentry-unity/pull/2930))
- The Event Sample Rate in the Sentry window now accepts values from 0.01 to 1.0. A rate of 0 made the SDK fail to initialize and builds fail to load the options. ([#2929](https://github.com/getsentry/sentry-unity/pull/2929))
Expand Down Expand Up @@ -231,7 +232,7 @@

### Features

- Added `options.AndroidNativeTombstoneEnabled` (default `false`) and `options.AndroidReportHistoricalTombstones` (default `false`) to enable reporting of native crashes captured by Android's `ApplicationExitInfo` API as Tombstones ([#2749](https://github.com/getsentry/sentry-unity/pull/2749))
- Added `options.AndroidTombstoneEnabled` (default `false`) and `options.AndroidReportHistoricalTombstones` (default `false`) to enable reporting of native crashes captured by Android's `ApplicationExitInfo` API as Tombstones ([#2749](https://github.com/getsentry/sentry-unity/pull/2749))

### Fixes

Expand Down
8 changes: 2 additions & 6 deletions src/Sentry.Unity.Editor/ConfigurationWindow/AdvancedTab.cs
Original file line number Diff line number Diff line change
Expand Up @@ -200,17 +200,13 @@ internal static void Display(ScriptableSentryUnityOptions options, SentryCliOpti
"constructed exception. Capture a thrown exception to include its stack trace.",
MessageType.Info);

if (!SentryUnityVersion.IsNewerOrEqualThan("2020.3"))
{
EditorGUILayout.HelpBox("The IL2CPP line number feature is supported from Unity version 2020.3 or newer and 2021.3 or newer onwards", MessageType.Warning);
}
else if (cliOptions is not null && !cliOptions.IsValid(null, EditorUserBuildSettings.development))
if (cliOptions is not null && !cliOptions.IsValid(null, EditorUserBuildSettings.development))
{
EditorGUILayout.BeginVertical(EditorStyles.helpBox);

var errorIcon = EditorGUIUtility.IconContent("console.erroricon").image;
var content = new GUIContent("The IL2CPP line number support relies on the Debug Symbol Upload to be enabled and configured." +
"\nAdditionally, this requires an Auth Token, an Org-Slug and the Project Name." +
"\nAdditionally, this requires an Auth Token and the Project Name, and the Org Slug unless the token is an organization token." +
"\nLearn more about how our IL2CPP support works in our docs.", errorIcon);
EditorGUILayout.LabelField(content, EditorStyles.wordWrappedLabel);

Expand Down
2 changes: 1 addition & 1 deletion src/Sentry.Unity.Editor/ConfigurationWindow/CoreTab.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ internal static void Display(ScriptableSentryUnityOptions options)

options.AutoSceneLoadTraces = EditorGUILayout.Toggle(
new GUIContent("Scene Traces ", "Whether the SDK should automatically create traces " +
"during scene loading. Requires Unity 2020.3 or newer."),
"during scene loading."),
options.AutoSceneLoadTraces);

options.AutoAwakeTraces = EditorGUILayout.Toggle(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@ internal static void Display(SentryCliOptions cliOptions)
new GUIContent(
"Auth Token",
cliOptions.UploadSymbols && string.IsNullOrWhiteSpace(cliOptions.Auth) ? SentryWindow.ErrorIcon : null,
"The authorization token from your user settings in Sentry"),
"The auth token sentry-cli uses to upload debug symbols, e.g. an organization token from your organization's settings in Sentry"),
cliOptions.Auth);

cliOptions.Organization = EditorGUILayout.TextField(
new GUIContent(
"Org Slug",
"The organization slug in Sentry"),
"The organization slug in Sentry. Required unless the Auth Token is an organization token."),
cliOptions.Organization);

cliOptions.Project = EditorGUILayout.TextField(
Expand Down
10 changes: 6 additions & 4 deletions src/Sentry.Unity.Editor/ConfigurationWindow/EnrichmentTab.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ internal static void Display(ScriptableSentryUnityOptions options)

options.IsEnvironmentUser = EditorGUILayout.Toggle(
new GUIContent("Auto Set UserName", "Whether to report the 'Environment.UserName' as " +
"the User affected in the event. Defaults to enabled on desktop " +
"platforms and disabled on mobile and console platforms."),
"the User affected in the event. Disabled by default."),
options.IsEnvironmentUser);

EditorGUI.indentLevel--;
Expand All @@ -34,8 +33,11 @@ internal static void Display(ScriptableSentryUnityOptions options)
options.AttachScreenshot = EditorGUILayout.BeginToggleGroup(
new GUIContent("Attach Screenshots to Events", "Try to attach current screenshot on events.\n" +
"This is an early-access feature and may not work on all platforms (it is explicitly disabled on WebGL).\n" +
"Additionally, the screenshot is captured mid-frame, when an event happens, so it may be incomplete.\n" +
"A screenshot might not be able to be attached, for example when the error happens on a background thread."),
"For C# events, the screenshot is taken at the end of the current or next frame, and none is " +
"attached in the Editor or in batch mode. It is missing when no frame completes within a second, " +
"for example while the main thread hangs or the app is paused in the background.\n" +
"On Windows, with native support enabled, native crashes get a screenshot of the game's window, taken by the " +
"native SDK when the crash happens (not in batch mode or server builds)."),
options.AttachScreenshot);
EditorGUI.indentLevel++;

Expand Down
4 changes: 2 additions & 2 deletions src/Sentry.Unity.Editor/SentryCliOptionsEditor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ public override void OnInspectorGUI()

EditorGUILayout.Toggle("Enable Symbols Upload", cliOptions.UploadSymbols);
EditorGUILayout.Toggle("Enable Dev Symbols Upload", cliOptions.UploadDevelopmentSymbols);
EditorGUILayout.TextField("Auth-Token", cliOptions.Auth);
EditorGUILayout.TextField("Org-Slug", cliOptions.Organization);
EditorGUILayout.TextField("Auth Token", cliOptions.Auth);
EditorGUILayout.TextField("Org Slug", cliOptions.Organization);
EditorGUILayout.TextField("Project Name", cliOptions.Project);

EditorGUILayout.LabelField("Options Configuration", EditorStyles.boldLabel);
Expand Down
3 changes: 2 additions & 1 deletion src/Sentry.Unity/SentryUnityOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,8 @@ public sealed class SentryUnityOptions : SentryOptions
public bool IosNativeSupportEnabled { get; set; } = true;

/// <summary>
/// Whether the SDK should add native support for iOS
/// Whether the SDK should report watchdog terminations on iOS: the app getting killed by the operating system,
/// for example for using too much memory. This is disabled by default.
/// </summary>
public bool IosWatchdogTerminationIntegrationEnabled { get; set; } = false;

Expand Down
Loading