diff --git a/packages/formbricks/CHANGELOG.md b/packages/formbricks/CHANGELOG.md index c643f52..2c2a6d5 100644 --- a/packages/formbricks/CHANGELOG.md +++ b/packages/formbricks/CHANGELOG.md @@ -1,5 +1,22 @@ # Changelog +## 1.1.0 + +- Support survey-interaction segment filters: segments that target contacts by + whether they have seen, started responding to, or completed a survey. The SDK + now pulls fresh segment membership after an interaction instead of waiting for + the user state to expire, so a rule like "completed survey A, show survey B" + fires in the same session. +- Bridge the survey runtime's `onFinished` callback, which the "have completed" + operators depend on. It fires only once the finished response has been accepted + by the backend. +- Fix a failing user-state flush surfacing as an unhandled async error. The + refresh is fire-and-forget, and `unawaited` does not handle errors. + +Only workspaces using interaction targeting see additional network activity: one +extra user-state request per interaction, gated per survey and per event and +debounced so a display, response and finish together cost a single request. + ## 1.0.0 First stable release. No API changes since 0.1.1 — promotes the SDK to a diff --git a/packages/formbricks/lib/src/user/interaction_refresh.dart b/packages/formbricks/lib/src/user/interaction_refresh.dart index a75f81b..b059af9 100644 --- a/packages/formbricks/lib/src/user/interaction_refresh.dart +++ b/packages/formbricks/lib/src/user/interaction_refresh.dart @@ -40,5 +40,10 @@ void refreshSegmentsAfterInteraction( // fire-and-forget — `unawaited` marks the future as intentionally not awaited but // does not handle its errors, so one would surface as an unhandled async error. // The queue already logs the real cause, so swallow it rather than report twice. - unawaited(queue.processUpdates().catchError((Object _) {})); + unawaited( + queue.processUpdates().catchError((Object _) { + // Intentionally empty. The queue already logged the real cause; this handler + // exists only so the error does not escape an unawaited future. + }), + ); } diff --git a/packages/formbricks/pubspec.yaml b/packages/formbricks/pubspec.yaml index 7298983..c8b5247 100644 --- a/packages/formbricks/pubspec.yaml +++ b/packages/formbricks/pubspec.yaml @@ -2,7 +2,7 @@ name: formbricks description: >- Formbricks Flutter SDK — connect your Flutter app to Formbricks, identify users, track actions, and render targeted in-app surveys. -version: 1.0.0 +version: 1.1.0 homepage: https://formbricks.com repository: https://github.com/formbricks/flutter issue_tracker: https://github.com/formbricks/flutter/issues