Conversation
Sample app builds 📱Below you will find the list of the latest versions of the sample apps. It's recommended to always download the latest builds of the sample apps to accurately test the pull request.
|
| // Only set up once to avoid duplicate streams | ||
| guard messagesStreamTask == nil else { | ||
| result(true) | ||
| return |
There was a problem hiding this comment.
iOS completed Task prevents inbox stream re-subscription
Medium Severity
The guard messagesStreamTask == nil check cannot distinguish between an active Task and a completed one. If the native inbox.messages(topic:) AsyncSequence terminates naturally (e.g., after SDK reset or user logout), the Task completes but messagesStreamTask remains non-nil. Subsequent calls to subscribeToInboxMessages would return early, silently preventing re-subscription. The Android counterpart avoids this by using a boolean flag (isInboxChangeListenerSetup) that gets explicitly reset in clearInboxChangeListener.


Summary
This PR adds support for upcoming feature of notification inbox.
Changes
Includes previously approved/merged PRs:
Note
Medium Risk
Adds new cross-platform method-channel surface area and native listener lifecycle handling; issues could manifest as missed events, duplicate subscriptions, or runtime errors when SDK/inbox isn’t initialized.
Overview
Adds Notification Inbox support to the Flutter in-app messaging plugin, exposing a new
CustomerIO.inAppMessaging.inboxAPI to fetch inbox messages (optionally by topic), stream real-time updates, and perform message actions (mark opened/unopened/deleted, track click).Implements the inbox bridge on Android and iOS via new method-channel handlers, message serialization helpers, and listener/task lifecycle cleanup to avoid duplicate subscriptions and leaks. Also bumps native SDK versions (
androidCustomer.io SDK4.15.2→4.16.0,iosnative_sdk_version4.1.2→4.2.0) and updates the sample app to include anInbox Messagesscreen for testing.Written by Cursor Bugbot for commit b7d56be. This will update automatically on new commits. Configure here.