Skip to content

26.8.0

Latest

Choose a tag to compare

@github-actions github-actions released this 02 Dec 00:37
05373b9
  • ! Major breaking change ! Removed these deprecated functions. The remote config replacements return a promise, and getValue returns null for a missing key:

    • Countly.recordView, use Countly.views.startAutoStoppedView
    • Countly.remoteConfigUpdate, use Countly.remoteConfig.update
    • Countly.updateRemoteConfigForKeysOnly, use Countly.remoteConfig.updateForKeysOnly
    • Countly.updateRemoteConfigExceptKeys, use Countly.remoteConfig.updateExceptKeys
    • Countly.getRemoteConfigValueForKey and Countly.getRemoteConfigValueForKeyP, use Countly.remoteConfig.getValue
    • Countly.remoteConfigClearValues, use Countly.remoteConfig.clearValues
  • ! Minor breaking change ! A remote config download no longer enrolls the user in A/B tests by default:

    • Add CountlyConfig.enrollABOnRCDownload() to enroll the user with every download, as before.
    • With it, Countly.remoteConfig.updateForKeysOnly and updateExceptKeys enroll the user only in the A/B tests of the downloaded keys in iOS, not in all running A/B tests.
  • ! Minor breaking change ! Every request is now sent as an HTTP POST. Countly.setHttpPostForced is deprecated and has no effect.

  • ! Minor breaking change ! Countly.d.ts now matches the API and compiles in strict mode. TypeScript code written against the old, looser types can get type errors, for example because Countly.deviceId.getID() now resolves to string | null.

  • ! Minor breaking change ! The package now needs React Native 0.65 or newer. It no longer contains the example app, the tests and the Xcode project for manual linking.

  • ! Minor breaking change ! The pod now needs iOS 15 instead of iOS 10. An app whose Podfile platform is lower, for example with React Native 0.75 or older, has to raise it; an app that has to support older iOS versions can stay on 26.1.0.

  • ! Minor breaking change ! The pod now makes only the bridge headers and the iOS SDK's public headers public; other headers can no longer be imported from it.

  • ! Minor breaking change ! Android now uses Firebase BoM 32.8.1 (firebase-messaging 23.4.1) instead of 28.4.2. Apps on an older Firebase BoM get its versions for their Firebase libraries.

  • ! Minor breaking change ! The Android SDK no longer depends on androidx.multidex:multidex; an app that uses it has to declare it itself.

  • ! Minor breaking change ! The Android SDK is now published at https://maven.countly.com. The bridge adds this repository to the app's projects; an app that declares its repositories in settings.gradle has to add it there:

    maven {
      url = 'https://maven.countly.com'
      content { includeGroupByRegex 'ly\\.count\\..*' }
    }
  • Added a { success, error } result to Countly.remoteConfig.update, updateForKeysOnly and updateExceptKeys.

  • Added Countly.registerForNotificationOpened(listener), called when the user taps a push in Android and iOS, also when the tap started the app. In Android, call setIntent(intent) in your MainActivity's onNewIntent so a tap that brings back a stopped app is delivered too.

  • Added support for objects as campaign data in recordDirectAttribution, in Countly and in CountlyConfig.

  • Added the names "DEVELOPMENT", "PRODUCTION" and "ADHOC" as accepted values of CountlyConfig.setPushTokenType.

  • Added CountlyConfig.setUpdateSessionTimerDelay(delay) to set how often, in seconds, the SDK sends automatic session updates and the queued events.

  • Added Countly.changeServerUrl(serverUrl) and Countly.changeAppKey(appKey) to change the server URL and the app key after init.

  • Added Countly.flushQueues() to delete the stored requests and events, and Countly.attemptToSendStoredRequests() to send the stored requests now.

  • Added CountlyConfig.setLogListener(listener) for receiving every log message of the SDK and its level, also while logging is disabled.

  • Added content triggers. While the content zone is entered, an action that starts a journey or campaign with content now requests that content immediately. Turn them off with CountlyConfig.content.disableAutoContentTriggers().

  • Added CountlyConfig.enableRequestCompression() for sending requests gzip-compressed to servers that support it.

  • Added CountlyConfig.disableHealthCheck() for turning off the SDK health check.

  • Added init config options of the underlying Android and iOS SDKs to CountlyConfig:

    • enableTemporaryDeviceIDMode() and enableClearStoredDeviceID() for the device ID the SDK starts with.
    • setEventQueueSizeToSend(threshold), setMaxRequestQueueSize(maxSize) and setRequestDropAgeHours(dropAgeHours) for the event and request queues.
    • giveAllConsents() and disableLocation().
    • setMetricOverride(metricOverride), setTrackOrientationChanges(shouldTrackOrientation), setUserProperties(userProperties) and setCustomCrashSegmentation(crashSegmentation).
    • enableRemoteConfigAutomaticTriggers(), enableRemoteConfigValueCaching() and remoteConfigRegisterGlobalCallback(callback), whose callback gets the result of every remote config download.
    • sdkInternalLimits.setMaxValueSizePicture(pictureValueSizeLimit).
  • Added support for server requested SDK log gathering and connection tests, and for SDK behavior settings that control automatic session tracking, automatic view tracking, automatic crash reporting and Journey Trigger Views.

  • Added the app's light or dark theme to feedback widgets, rating widgets and content, so they are shown to match the app.

  • Improved journey triggers set in SDK behavior settings. Their events and views now request content immediately, the same way as content triggers.

  • The NotificationService pod subspec no longer depends on React.

  • Mitigated an issue where Countly.logException recorded every exception as non-fatal, also with nonfatal set to false.

  • Mitigated an issue where an uncaught JS error that crashed a release build was recorded twice. It is now recorded once, as a fatal crash with its JS stack.

  • Mitigated an issue where Countly.remoteConfig.getValue returned string values that look like numbers as numbers in Android, for example "2.10" as 2.1.

  • Mitigated remote config update issues:

    • Updates without remote config consent, in temporary device ID mode or with SDK networking disabled now complete with an error in iOS, instead of never completing.
    • An update without remote config consent is now reported as failed in Android.
  • Mitigated crash reporting issues:

    • The JS crash handler no longer fails, or skips the app's previous error handler, when the app throws a value that is not an Error.
    • Countly.logException now accepts Error objects, and skips null and undefined segment values instead of failing.
    • JS crash titles now name the function and the bundle file the error came from, by file name only, without device or build paths.
  • Mitigated SDK behavior settings issues:

    • The settings were ignored with servers from 26.01.8 to 26.10.0.
    • A setting removed in SDK Manager did not go back to its CountlyConfig value or the SDK default.
    • CountlyConfig.disableBackoffMechanism did not always take effect.
    • Changed settings did not reach an app that stayed in the foreground in Android.
    • In iOS, refreshing the settings after the app came back from the background could reset the init config, such as the consent requirement, until the next start.
    • In iOS, settings sent as false or 0 did not override the init config, and the default settings overrode the SDK limits set in it.
    • In iOS, with location tracking turned off in the settings, the requests queued at start, the session begin included, were held back.
  • Mitigated view issues:

    • A view ID returned by Countly.views.startView stopped working after the app went to the background and came back.
    • An auto-stopped view could stop being tracked when the app came back from the background.
  • Mitigated an issue where links that carry their own query parameters, such as deep links, were not parsed correctly in content and feedback widgets.

  • Mitigated an issue where some requests in temporary device ID mode created a CLYTemporaryDeviceID user on the server.

  • Mitigated an issue where session, view, timed event and custom trace durations changed when the device clock was adjusted, and events recorded with a negative duration kept it.

  • Mitigated an issue where the health check sent data without the metrics consent.

  • Mitigated an issue where the release build of an app on React Native 0.72 or older failed with "Class private methods are not enabled" in Feedback.js.

  • Mitigated an issue where the "enter content zone" SDK behavior setting could exit a content zone the app entered. The setting now applies only when the SDK starts.

  • Mitigated an issue where CountlyConfig.setLocation was ignored without a country code in iOS.

  • Mitigated start-up issues:

    • An empty or null device ID at init no longer becomes the device ID "null" in Android; the SDK generates one instead, and installs that already have "null" get a new ID on their next start.
    • A partly set push config, a single consent name instead of a list, or attribution data of the wrong type no longer skips the rest of the init config in Android, or crashes the app.
    • Countly.initWithConfig now refuses a missing server URL or app key with an error log, and its promise settles when the native init fails.
  • Mitigated push notification issues:

    • A token handed over with Countly.sendPushToken is now registered without calling Countly.askForNotificationPermission first in Android, and a token renewed by Firebase while the SDK runs is sent.
    • Countly.sendPushToken now sends the token in iOS, with the token type set by CountlyConfig.setPushTokenType, also when Countly push notifications are disabled.
    • Countly.askForNotificationPermission now shows the notification permission prompt on Android 13 and newer; the bridge declares POST_NOTIFICATIONS for it.
    • Registering Countly.registerForNotification again now replaces the earlier listener, so each push reaches JS once.
    • In iOS, a push tapped while the app starts is now counted once, and the push token is no longer sent before the user allows notifications.
  • Mitigated data issues:

    • Event sums keep their full precision in iOS.
    • Whole numbers in user properties are now sent without exponent notation in Android, for example 5551234567 instead of 5.551234567E9.
    • null values and numbers in data the bridge returns to JS now arrive as null and numbers in Android.
    • The "metrics" consent can now be given and removed after init in Android.
    • incrementBy, multiply, saveMax and saveMin in Countly.userData and Countly.userDataBulk no longer send a changed value for decimals or numbers outside the 32-bit integer range; they refuse them with an error message.
  • Mitigated an issue where Countly.recordMetrics before init, a survey reported as closed with a null result, or inputs of the wrong type could crash the app or leave a promise unsettled.

  • Mitigated an issue where the content callback status was a number in iOS; it is now the text "COMPLETED" or "CLOSED", the same as in Android.

  • Mitigated an issue where the iOS privacy manifest was not bundled with the pod.

  • No-push package (countly-sdk-react-native-bridge-np) specific changes:

    • Android now reports the SDK name js-rnbnp-android, which the server recognizes, instead of js-rnb-android-np.
    • iOS no longer compiles push notification code.
    • Push notification calls and push config options are ignored with a warning log.
  • Android specific changes:

    • ! Minor breaking change ! Content, feedback widget and push notification links with the data:, zip: or intent: scheme are no longer opened, and web views no longer load resources from them.
    • Added large icons and collapse keys to push notifications. A large icon given only by resource name needs a tools:keep entry when the app shrinks its resources.
    • Added support for API level 37.
    • Mitigated an issue where, with automatic view tracking, coming back to an activity that had not been stopped, for example when a translucent activity closed, did not record that activity's view again.
    • Mitigated content and feedback widget issues:
      • Closing a content or feedback widget from a background thread crashed the app.
      • Content could stay hidden on some devices after it had loaded.
      • The widgets blocked keyboard input on the app's screen.
      • The content zone did not resume after the app left temporary device ID mode.
      • Content and feedback widgets could keep their previous size after a rotation, leaving part of them off screen.
    • Mitigated an issue where the app was treated as being in the background after moving from one activity to another, so crash reports were marked as happening in the background.
    • Mitigated StrictMode violations the SDK caused.
    • Mitigated push notification issues:
      • Images could delay a notification or keep it from showing.
      • An action button tap left the notification visible.
      • The app could crash when the screen of a push notification dialog closed before its image loaded.
      • The token was not sent again after push consent was given again or after a device ID change without merge.
  • iOS specific changes:

    • ! Minor breaking change ! A SIGPIPE the app neither ignores nor handles itself now ends the app after the crash is reported, as it would without the SDK:
      • Before, the SDK reported it, kept the app running and turned automatic crash reporting off.
      • An app that has to survive a broken pipe should ignore or handle SIGPIPE before Countly.initWithConfig.
    • Countly.content.exitContentZone now also closes the content on screen.
    • Crashes are now also passed on to crash reporting tools that the app started before the SDK.
    • Mitigated an issue where the request queue could drop or duplicate requests.
    • Mitigated an issue where the app could freeze instead of terminating on some crashes.
    • Mitigated possible crashes, repeated on every start, when a server or proxy sent an unexpected answer.
    • Mitigated an issue where certificate pinning was not applied to SDK behavior settings, remote config, feedback widget, content and health check requests.
    • Mitigated an issue where a feedback widget that failed to load was recorded as closed by the user, which could keep it hidden from that user.
    • Mitigated an issue where Countly.userData.setProperty and Countly.userDataBulk.setProperty with a predefined key (name, username, email, organization, phone, gender, picture, picturePath, byear) recorded a custom property of that name; they now set that field, as on Android.
    • Mitigated an issue where null values and nested objects in user properties were sent; they are now skipped with a log line, as on Android.
    • Mitigated an issue where journey trigger events and views with keys longer than the key length limit never matched.
    • Mitigated an issue where the orientation was not recorded at start, and not at all on iOS 27 in apps that use the UIScene lifecycle.
  • Updated the underlying Android SDK version to 26.8.1

  • Updated the underlying iOS SDK version to 26.8.1