Releases: BatchLabs/Batch-Android-SDK
Releases · BatchLabs/Batch-Android-SDK
1.19.0
Core
- Batch now compiles and targets SDK 32 (Android 12L).
- Important change: Batch now declares to use the
android.permission.POST_NOTIFICATIONS
permission in its manifest. If you want to remove it, add<uses-permission android:name="android.permission.POST_NOTIFICATIONS" tools:node="remove" />
in your app's AndroidManifest. - Fixed some rare ANRs produced when receiving push.
- Identical push messages sent twice by FCM will now only be displayed once.
- Batch will now try to display FCM high priority push notifications directly rather than scheduling a Job.
Event Dispatchers
- Added
getName
andgetVersion
onBatchEventDispatcher
. If you are using a Batch dispatcher plugin, please update it.
Messaging
- Added global frequency capping management for in-app campaigns.
- Improved the way In-App campaigns are triggered.
- Added just-in-time verification for in-app campaigns.
Inbox
- Added the ability to disable the filtering of silent notifications on
BatchInboxFetcher
using thesetFilterSilentNotifications
method. - Important change: Silent notifications are now filtered by default: use the new property if you relied on the previous behaviour.
This brings the Android SDK in line with its iOS counterpart, which has always filtered silent notifications as expected.
1.18.2
Core
- Fixed an issue where the AAR's shrinking would result in classes being repackaged as generic names outside of "com.batch.android".
This could have caused package collisions in some cases. The shrinking behaviour now matches pre-1.18 releases.
Messaging
- Fixed some rare crashes and improved out of memory handling in In-App Messaging.
- Improved error handling in WebView In-Apps. They should now behave more like a browser when encountering load failures.
- Changed the way In-App campaigns start and end dates are computed on Samsung devices to be more reliable.
- Prevent Xiaomi devices from overriding theme colors in dark mode.
Debug
- Fixed an issue where the FindMyInstallation feature could lead to a crash.
1.18.1
1.18.0
Core
- Fixed detection of indonesian, hebrew and yiddish languages.
- Improved how the device locale is detected to better support language variations.
- Fixed an issue where the direct opens weren't always tracked in singleTop/singleTask activities using
onNewIntent
.
Events
- The event tracker now retries less aggressively in deteriorated network conditions.
- Added URL type (using
java.net.URI
) in event data.
Attributes
- Added URL type in custom attributes.
Messaging
- Fixed an issue where in-app campaigns could lead to a crash of the app when swiping to dismiss.
- Added support for Activity Exclusion. This allows to easily exclude some activities such as a splash screen from Batch rather than having to implement a Do Not Disturb mode. Intent forwarding is automatically handled by the SDK.
Push
- Added compatibility with FCM Tokens. Batch now supports firebase-messaging 22.0.0 natively without having to add
firebase-iid
.
Inbox
- Batch will now cache notifications marked as read or deleted to avoid any synchronization issues.
- Method
isDeleted()
from BatchInboxNotificationContent is now deprecated.
Debug
- Fixed an issue where the debug activity would show the advertising identifier even if it was disabled. The bug was purely cosmetic and the identifier was not sent to Batch.
- Batch will now copy the installation ID to the clipboard when the application is foregrounded multiple times in a short timespan. This is enabled by default, you can disable it at any moment by using
Batch.setFindMyInstallationEnabled(false)
.
1.17.3
Event Dispatchers
- Fixed an issue where event dispatchers added via
Batch.EventDispatcher.addDispatcher()
were unregistered when Batch stopped: they will stay registered.
Statically declared (such as Batch's builtin ones) were unregistered and re-registered on start: those are now loaded only once in the Application's lifetime.
1.17.2
Core
- Added a package query entry in AndroidManifest.xml for
com.android.vending
to make Play Store detection work more accurately on Huawei devices.
Messaging
- Fix in-app campaigns cache being unreadable.
User
- Fixed an issue where builtin event track action would not be able to parse dates on Lollipop and lower.
1.17.1
Core
- Fixed a memory leak due to Batch retaining the first activity that appeared on screen.
Actions
- Fixed a bug where
batch.user.event
would fail is no event label was specified. This aligns the behaviour with iOS' implementation.
User
- Tracking an event with an empty label now behaves as if the label was null. Event labels that are only composed of whitespaces are unchanged for compatibility.
Messaging
- Caching has been disabled on the WebView format.
1.17.0
Core
- Added a package query entry in AndroidManifest.xml for
com.huawei.appmarket
to enable detection of the Huawei AppGallery. - Added missing
android:exported
manifest attributes in preparation for Android 12.
Actions
- Added
batch.rating
, which asks the user to review your app using the Google Play In-App Review API.
To enable in-app review, add thecom.google.android.play:core
dependency to your project.
If the library is missing or fails, the SDK will open the Play Store/Huawei AppGallery. - Added
batch.clipboard
, which can copy text to the clipboard.
Messaging
- Added support for a new UI format: WebView. See documentation for more info.
- Added
onBatchMessageCancelledByError
onBatch.Messaging.LifecycleListener
, called when a message could not be loaded due to an error when loading the message's content. - Added
onBatchMessageWebViewActionTriggered
onBatch.Messaging.LifecycleListener
, called when a in-app webview format action has been triggered. - In-App campaign cache is now cleared on server errors
Push
- Important change: Push open pending intents are now created with
FLAG_IMMUTABLE
on Android M and higher in preparation for Android 12.
This also applies toPendingIntent
instances returned byBatch.Push.makePendingIntent*()
methods.
Event Dispatchers
- Added the new event types
MESSAGING_CLOSE_ERROR
andMESSAGING_WEBVIEW_CLICK
. See javadoc for more info.
1.16.3
Core
- Fix an issue where Batch might lose some module configuration (such as the push small icon) when an activity is destroyed and no other is on screen.
Push
- Fix a bug where query parameters of rich push media URLs were escaped twice, making use of non URL safe characters impossible.