-
-
Notifications
You must be signed in to change notification settings - Fork 229
Closed
Milestone
Description
BatteryLevel
sentry-dotnet/src/Sentry/Protocol/Device.cs
Lines 430 to 436 in de216fa
| // TODO: For next major: Remove this and change BatteryLevel from short to float | |
| // The Java and Cocoa SDK report the battery as `float` | |
| // Cocoa https://github.com/getsentry/sentry-cocoa/blob/e773cad622b86735f1673368414009475e4119fd/Sources/Sentry/include/SentryUIDeviceWrapper.h#L18 | |
| // Java https://github.com/getsentry/sentry-java/blob/25f1ca4e1636a801c17c1662f0145f888550bce8/sentry/src/main/java/io/sentry/protocol/Device.java#L231-L233 | |
| var batteryLevel = json.GetPropertyOrNull("battery_level")?.TryGetDouble(out var level) is true | |
| ? (short)level | |
| : (short?)null; |
- Change Device.BatteryLevel from short to float
- Tests to avoid regressions (i.e. Java changes the underlying types)
- fix:
FormatExceptionwhen readingBatteryLevel#3485
ProcessorFrequency
sentry-dotnet/src/Sentry/Protocol/Device.cs
Lines 457 to 462 in de216fa
| // TODO: For next major: Remove this and change ProcessorFrequency from int to float | |
| // The Java SDK reports the processorFrequency as `double` | |
| // Java https://github.com/getsentry/sentry-java/blob/9762f09afa51944b40a9b77e116a55e54636e6c5/sentry/src/main/java/io/sentry/protocol/Device.java#L130 | |
| var processorFrequency = json.GetPropertyOrNull("processor_frequency")?.TryGetDouble(out var frequency) is true | |
| ? (int)frequency | |
| : (int?)null; |
- Change Device.ProcessorFrequency from int to float
- Tests to avoid regressions (i.e. Java changes the underlying types)
- fix:
FormatExceptionwhen readingProcessorFrequency#3541
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Projects
Status
Done