Skip to content

Commit 7a59034

Browse files
committed
Keep the key
1 parent fac1ab4 commit 7a59034

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

src/Sentry/Protocol/Mechanism.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,10 @@ public sealed class Mechanism : ISentryJsonSerializable
3030
public static readonly string DescriptionKey = "Sentry:Description";
3131

3232
/// <summary>
33-
/// Key found inside of <c>Exception.Data</c> describing whether the exception is considered terminal
33+
/// Key found inside of <c>Exception.Data</c> describing whether the exception is considered terminal.
3434
/// </summary>
35-
public static readonly string TerminalKey = "Sentry:Terminal";
35+
/// <remarks> It's not prefixed with 'Sentry' so the MainExceptionProcessor does not remove it. </remarks>
36+
public static readonly string TerminalKey = "Terminal";
3637

3738
internal Dictionary<string, object>? InternalData { get; private set; }
3839

test/Sentry.Tests/Protocol/Exceptions/MechanismTests.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,6 @@ public static IEnumerable<object[]> TestCases()
7373
yield return new object[] { (new Mechanism { Description = "some desc" }, """{"type":"generic","description":"some desc"}""") };
7474
yield return new object[] { (new Mechanism { Data = { new KeyValuePair<string, object>("data-key", "data-value") } }, """{"type":"generic","data":{"data-key":"data-value"}}""") };
7575
yield return new object[] { (new Mechanism { Meta = { new KeyValuePair<string, object>("meta-key", "meta-value") } }, """{"type":"generic","meta":{"meta-key":"meta-value"}}""") };
76-
yield return new object[] { (new Mechanism { Data = { new KeyValuePair<string, object>(Mechanism.TerminalKey, true) } }, """{"type":"generic","data":{"Sentry:Terminal":true}}""") };
77-
yield return new object[] { (new Mechanism { Data = { new KeyValuePair<string, object>(Mechanism.TerminalKey, false) } }, """{"type":"generic","data":{"Sentry:Terminal":false}}""") };
7876
}
7977

8078
[Fact]

0 commit comments

Comments
 (0)