From 1f6f4abf666b68ac25b1655a771ba4e1f11ecfa2 Mon Sep 17 00:00:00 2001 From: Ivan Dlugos Date: Tue, 10 Dec 2024 11:00:52 +0100 Subject: [PATCH 1/3] chore: prepare changelog for 8.11.0 release --- CHANGELOG.md | 110 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 110 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ceb9af57b..648fe685c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,115 @@ # Changelog +## Unreleased + +### Features + +- Support for screenshot PII content masking ([#2361](https://github.com/getsentry/sentry-dart/pull/2361)) + By default, masking is enabled for SessionReplay. To also enable it for screenshots captured with events, you can specify `options.experimental.privacy`: + + ```dart + await SentryFlutter.init( + (options) { + ... + // the defaults are: + options.experimental.privacy.maskAllText = true; + options.experimental.privacy.maskAllImages = true; + options.experimental.privacy.maskAssetImages = false; + // you cal also set up custom masking, for example: + options.experimental.privacy.mask(); + }, + appRunner: () => runApp(MyApp()), + ); + ``` + + Actually, just accessing this field will cause it to be initialized with the default settings to mask all text and images: + + ```dart + await SentryFlutter.init( + (options) { + ... + // this has a side-effect of creating the default privacy configuration, thus enabling Screenshot masking: + options.experimental.privacy; + }, + appRunner: () => runApp(MyApp()), + ); + ``` + +- Linux native error & obfuscation support ([#2431](https://github.com/getsentry/sentry-dart/pull/2431)) +- Improve Device context on plain Dart and Flutter desktop apps ([#2441](https://github.com/getsentry/sentry-dart/pull/2441)) +- Add debounce to capturing screenshots ([#2368](https://github.com/getsentry/sentry-dart/pull/2368)) + - Per default, screenshots are debounced for 2 seconds. + - If you need more granular screenshots, you can opt out of debouncing: + + ```dart + await SentryFlutter.init((options) { + options.beforeCaptureScreenshot = (event, hint, debounce) { + if (debounce) { + return true; // Capture screenshot even if the SDK wants to debounce it. + } else { + // check event and hint + ... + } + }; + }); + ``` + + - Replace deprecated `BeforeScreenshotCallback` with new `BeforeCaptureCallback`. + +- Windows native error & obfuscation support ([#2286](https://github.com/getsentry/sentry-dart/pull/2286), [#2426](https://github.com/getsentry/sentry-dart/pull/2426)) +- Improve app start measurements by using `addTimingsCallback` instead of `addPostFrameCallback` to determine app start end ([#2405](https://github.com/getsentry/sentry-dart/pull/2405)) + - ⚠️ This change may result in reporting of shorter app start durations +- Improve frame tracking accuracy ([#2372](https://github.com/getsentry/sentry-dart/pull/2372)) + - Introduces `SentryWidgetsFlutterBinding` that tracks a frame starting from `handleBeginFrame` and ending in `handleDrawFrame`, this is approximately the [buildDuration](https://api.flutter.dev/flutter/dart-ui/FrameTiming/buildDuration.html) time + - By default, `SentryFlutter.init()` automatically initializes `SentryWidgetsFlutterBinding` through the `WidgetsFlutterBindingIntegration` + - If you need to initialize the binding before `SentryFlutter.init`, use `SentryWidgetsFlutterBinding.ensureInitialized` instead of `WidgetsFlutterBinding.ensureInitialized`: + + ```dart + void main() async { + // Replace WidgetsFlutterBinding.ensureInitialized() + SentryWidgetsFlutterBinding.ensureInitialized(); + + await SentryFlutter.init(...); + runApp(MyApp()); + } + ``` + + - ⚠️ Frame tracking will be disabled if a different binding is used + +### Enhancements + +- Only send debug images referenced in the stacktrace for events ([#2329](https://github.com/getsentry/sentry-dart/pull/2329)) +- Remove `sentry` frames if SDK falls back to current stack trace ([#2351](https://github.com/getsentry/sentry-dart/pull/2351)) + - Flutter doesn't always provide stack traces for unhandled errors - this is normal Flutter behavior + - When no stack trace is provided (in Flutter errors, `captureException`, or `captureMessage`): + - SDK creates a synthetic trace using `StackTrace.current` + - Internal SDK frames are removed to reduce noise + - Original stack traces (when provided) are left unchanged + +### Fixes + +- Catch errors thrown during `handleBeginFrame` and `handleDrawFrame` ([#2446](https://github.com/getsentry/sentry-dart/pull/2446)) +- OS & device contexts missing on Windows ([#2439](https://github.com/getsentry/sentry-dart/pull/2439)) +- Native iOS/macOS SDK session didn't start after Flutter hot-restart ([#2452](https://github.com/getsentry/sentry-dart/pull/2452)) +- Kotlin 2.1.0 compatibility on Android, bump Kotlin language version from `1.4` to `1.6` ([#2456](https://github.com/getsentry/sentry-dart/pull/2456)) +- Apply default IP address (`{{auto}}`) to transactions ([#2395](https://github.com/getsentry/sentry-dart/pull/2395)) + - Previously, transactions weren't getting the default IP address when user context was loaded + - Now consistently applies default IP address to both events and transactions when: + - No user context exists + - User context exists but IP address is null + +### Dependencies + +- Bump Cocoa SDK from v8.40.1 to v8.41.0 ([#2442](https://github.com/getsentry/sentry-dart/pull/2442)) + - [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8410) + - [diff](https://github.com/getsentry/sentry-cocoa/compare/8.40.1...8.41.0) +- Bump Android SDK from v7.16.0 to v7.18.1 ([#2408](https://github.com/getsentry/sentry-dart/pull/2408), [#2419](https://github.com/getsentry/sentry-dart/pull/2419), [#2457](https://github.com/getsentry/sentry-dart/pull/2457)) + - [changelog](https://github.com/getsentry/sentry-java/blob/main/CHANGELOG.md#7181) + - [diff](https://github.com/getsentry/sentry-java/compare/7.16.0...7.18.1) +- Bump Native SDK from v0.7.12 to v0.7.15 ([#2430](https://github.com/getsentry/sentry-dart/pull/2430)) + - [changelog](https://github.com/getsentry/sentry-native/blob/master/CHANGELOG.md#0715) + - [diff](https://github.com/getsentry/sentry-native/compare/0.7.12...0.7.15) + ## 8.11.0-beta.2 ### Features From 617ae186a50bf2f4067155a3689f67c756a80035 Mon Sep 17 00:00:00 2001 From: getsentry-bot Date: Tue, 10 Dec 2024 11:40:09 +0000 Subject: [PATCH 2/3] release: 8.11.0 --- CHANGELOG.md | 2 +- dart/lib/src/version.dart | 2 +- dart/pubspec.yaml | 2 +- dio/lib/src/version.dart | 2 +- dio/pubspec.yaml | 4 ++-- drift/lib/src/version.dart | 2 +- drift/pubspec.yaml | 4 ++-- file/lib/src/version.dart | 2 +- file/pubspec.yaml | 4 ++-- flutter/example/pubspec.yaml | 2 +- flutter/lib/src/version.dart | 2 +- flutter/pubspec.yaml | 4 ++-- hive/lib/src/version.dart | 2 +- hive/pubspec.yaml | 4 ++-- isar/lib/src/version.dart | 2 +- isar/pubspec.yaml | 4 ++-- logging/lib/src/version.dart | 2 +- logging/pubspec.yaml | 4 ++-- sqflite/lib/src/version.dart | 2 +- sqflite/pubspec.yaml | 4 ++-- 20 files changed, 28 insertions(+), 28 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 648fe685c..66c3006ed 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## Unreleased +## 8.11.0 ### Features diff --git a/dart/lib/src/version.dart b/dart/lib/src/version.dart index 7afded925..d1f0aa94e 100644 --- a/dart/lib/src/version.dart +++ b/dart/lib/src/version.dart @@ -9,7 +9,7 @@ library version; /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; String sdkName(bool isWeb) => isWeb ? _browserSdkName : _ioSdkName; diff --git a/dart/pubspec.yaml b/dart/pubspec.yaml index 59fced89d..a67131942 100644 --- a/dart/pubspec.yaml +++ b/dart/pubspec.yaml @@ -1,5 +1,5 @@ name: sentry -version: 8.11.0-beta.2 +version: 8.11.0 description: > A crash reporting library for Dart that sends crash reports to Sentry.io. This library supports Dart VM and Web. For Flutter consider sentry_flutter instead. diff --git a/dio/lib/src/version.dart b/dio/lib/src/version.dart index 44ee32b55..6c0256435 100644 --- a/dio/lib/src/version.dart +++ b/dio/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The package name reported to Sentry.io in the submitted events. const String packageName = 'pub:sentry_dio'; diff --git a/dio/pubspec.yaml b/dio/pubspec.yaml index 066b5c812..d390a9e1a 100644 --- a/dio/pubspec.yaml +++ b/dio/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_dio description: An integration which adds support for performance tracing for the Dio package. -version: 8.11.0-beta.2 +version: 8.11.0 homepage: https://docs.sentry.io/platforms/dart/ repository: https://github.com/getsentry/sentry-dart issue_tracker: https://github.com/getsentry/sentry-dart/issues @@ -19,7 +19,7 @@ platforms: dependencies: dio: ^5.0.0 - sentry: 8.11.0-beta.2 + sentry: 8.11.0 dev_dependencies: meta: ^1.3.0 diff --git a/drift/lib/src/version.dart b/drift/lib/src/version.dart index b24d09c64..656652fa8 100644 --- a/drift/lib/src/version.dart +++ b/drift/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The package name reported to Sentry.io in the submitted events. const String packageName = 'pub:sentry_drift'; diff --git a/drift/pubspec.yaml b/drift/pubspec.yaml index 977314a1a..141bf7b05 100644 --- a/drift/pubspec.yaml +++ b/drift/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_drift description: An integration which adds support for performance tracing for the drift package. -version: 8.11.0-beta.2 +version: 8.11.0 homepage: https://docs.sentry.io/platforms/flutter/ repository: https://github.com/getsentry/sentry-dart issue_tracker: https://github.com/getsentry/sentry-dart/issues @@ -17,7 +17,7 @@ platforms: web: dependencies: - sentry: 8.11.0-beta.2 + sentry: 8.11.0 meta: ^1.3.0 drift: ^2.13.0 diff --git a/file/lib/src/version.dart b/file/lib/src/version.dart index 47269cb4c..162da555a 100644 --- a/file/lib/src/version.dart +++ b/file/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The package name reported to Sentry.io in the submitted events. const String packageName = 'pub:sentry_file'; diff --git a/file/pubspec.yaml b/file/pubspec.yaml index f590b6ab8..5429bbb06 100644 --- a/file/pubspec.yaml +++ b/file/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_file description: An integration which adds support for performance tracing for dart.io.File. -version: 8.11.0-beta.2 +version: 8.11.0 homepage: https://docs.sentry.io/platforms/dart/ repository: https://github.com/getsentry/sentry-dart issue_tracker: https://github.com/getsentry/sentry-dart/issues @@ -17,7 +17,7 @@ platforms: windows: dependencies: - sentry: 8.11.0-beta.2 + sentry: 8.11.0 meta: ^1.3.0 dev_dependencies: diff --git a/flutter/example/pubspec.yaml b/flutter/example/pubspec.yaml index cb1d55bf0..1bf1e2d74 100644 --- a/flutter/example/pubspec.yaml +++ b/flutter/example/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_flutter_example description: Demonstrates how to use the sentry_flutter plugin. -version: 8.11.0-beta.2 +version: 8.11.0 publish_to: 'none' # Remove this line if you wish to publish to pub.dev diff --git a/flutter/lib/src/version.dart b/flutter/lib/src/version.dart index 3a1bd7ac5..be9882fd5 100644 --- a/flutter/lib/src/version.dart +++ b/flutter/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The default SDK name reported to Sentry.io in the submitted events. const String sdkName = 'sentry.dart.flutter'; diff --git a/flutter/pubspec.yaml b/flutter/pubspec.yaml index 03ece806b..9bdb3c186 100644 --- a/flutter/pubspec.yaml +++ b/flutter/pubspec.yaml @@ -1,5 +1,5 @@ name: sentry_flutter -version: 8.11.0-beta.2 +version: 8.11.0 description: Sentry SDK for Flutter. This package aims to support different Flutter targets by relying on the many platforms supported by Sentry with native SDKs. homepage: https://docs.sentry.io/platforms/flutter/ repository: https://github.com/getsentry/sentry-dart @@ -23,7 +23,7 @@ dependencies: sdk: flutter flutter_web_plugins: sdk: flutter - sentry: 8.11.0-beta.2 + sentry: 8.11.0 package_info_plus: '>=1.0.0' meta: ^1.3.0 ffi: ^2.0.0 diff --git a/hive/lib/src/version.dart b/hive/lib/src/version.dart index bacc5dcc8..feec20e9d 100644 --- a/hive/lib/src/version.dart +++ b/hive/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The package name reported to Sentry.io in the submitted events. const String packageName = 'pub:sentry_hive'; diff --git a/hive/pubspec.yaml b/hive/pubspec.yaml index b8cf392d1..bbdce4a73 100644 --- a/hive/pubspec.yaml +++ b/hive/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_hive description: An integration which adds support for performance tracing for the hive package. -version: 8.11.0-beta.2 +version: 8.11.0 homepage: https://docs.sentry.io/platforms/flutter/ repository: https://github.com/getsentry/sentry-dart issue_tracker: https://github.com/getsentry/sentry-dart/issues @@ -17,7 +17,7 @@ platforms: web: dependencies: - sentry: 8.11.0-beta.2 + sentry: 8.11.0 hive: ^2.2.3 meta: ^1.3.0 diff --git a/isar/lib/src/version.dart b/isar/lib/src/version.dart index cd7641479..e6f2293be 100644 --- a/isar/lib/src/version.dart +++ b/isar/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The package name reported to Sentry.io in the submitted events. const String packageName = 'pub:sentry_isar'; diff --git a/isar/pubspec.yaml b/isar/pubspec.yaml index 7518dd9b3..587b8f3e3 100644 --- a/isar/pubspec.yaml +++ b/isar/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_isar description: An integration which adds support for performance tracing for the isar package. -version: 8.11.0-beta.2 +version: 8.11.0 homepage: https://docs.sentry.io/platforms/flutter/ repository: https://github.com/getsentry/sentry-dart issue_tracker: https://github.com/getsentry/sentry-dart/issues @@ -20,7 +20,7 @@ platforms: dependencies: isar: ^3.1.0 isar_flutter_libs: ^3.1.0 # contains Isar Core - sentry: 8.11.0-beta.2 + sentry: 8.11.0 meta: ^1.3.0 path: ^1.8.3 diff --git a/logging/lib/src/version.dart b/logging/lib/src/version.dart index 8793c9ea8..8586afc14 100644 --- a/logging/lib/src/version.dart +++ b/logging/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The package name reported to Sentry.io in the submitted events. const String packageName = 'pub:sentry_logging'; diff --git a/logging/pubspec.yaml b/logging/pubspec.yaml index 706b409ac..f5760d2ed 100644 --- a/logging/pubspec.yaml +++ b/logging/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_logging description: An integration which adds support for recording log from the logging package. -version: 8.11.0-beta.2 +version: 8.11.0 homepage: https://docs.sentry.io/platforms/dart/ repository: https://github.com/getsentry/sentry-dart issue_tracker: https://github.com/getsentry/sentry-dart/issues @@ -19,7 +19,7 @@ platforms: dependencies: logging: ^1.0.0 - sentry: 8.11.0-beta.2 + sentry: 8.11.0 dev_dependencies: lints: '>=2.0.0' diff --git a/sqflite/lib/src/version.dart b/sqflite/lib/src/version.dart index 5f101b1aa..cc7043409 100644 --- a/sqflite/lib/src/version.dart +++ b/sqflite/lib/src/version.dart @@ -1,5 +1,5 @@ /// The SDK version reported to Sentry.io in the submitted events. -const String sdkVersion = '8.11.0-beta.2'; +const String sdkVersion = '8.11.0'; /// The package name reported to Sentry.io in the submitted events. const String packageName = 'pub:sentry_sqflite'; diff --git a/sqflite/pubspec.yaml b/sqflite/pubspec.yaml index 37b636df5..20fd6c579 100644 --- a/sqflite/pubspec.yaml +++ b/sqflite/pubspec.yaml @@ -1,6 +1,6 @@ name: sentry_sqflite description: An integration which adds support for performance tracing for the sqflite package. -version: 8.11.0-beta.2 +version: 8.11.0 homepage: https://docs.sentry.io/platforms/flutter/ repository: https://github.com/getsentry/sentry-dart issue_tracker: https://github.com/getsentry/sentry-dart/issues @@ -15,7 +15,7 @@ platforms: macos: dependencies: - sentry: 8.11.0-beta.2 + sentry: 8.11.0 sqflite: ^2.2.8 sqflite_common: ^2.0.0 meta: ^1.3.0 From 161a1d54294aba0117b64f630562088ad9d7f012 Mon Sep 17 00:00:00 2001 From: Ivan Dlugos <6349682+vaind@users.noreply.github.com> Date: Tue, 10 Dec 2024 14:01:54 +0100 Subject: [PATCH 3/3] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d055860b0..5785ed2e2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -31,7 +31,7 @@ ### Fixes - Masking semi-transparent widgets ([#2472](https://github.com/getsentry/sentry-dart/pull/2472)) -- + ## 8.11.0 ### Features