Skip to content

task(SDK-5520) - Release v3.9.0#494

Merged
Anush-Shand merged 3 commits intodevelopfrom
task/SDK-5520/release_3.9.0
Feb 17, 2026
Merged

task(SDK-5520) - Release v3.9.0#494
Anush-Shand merged 3 commits intodevelopfrom
task/SDK-5520/release_3.9.0

Conversation

@Anush-Shand
Copy link
Contributor

@Anush-Shand Anush-Shand commented Feb 11, 2026

Inaction and NestedObject support

Summary by CodeRabbit

  • New Features

    • Support for nested object ingestion in event and profile properties (Android & iOS).
    • Support for server-side in-app notifications (Android & iOS).
    • Example app UI extended to demonstrate nested-properties workflows for profile, login, and event recording.
    • Date handling enhanced to convert dates within nested objects/arrays consistently.
  • Updates

    • CleverTap Android SDK → v7.8.0; iOS SDK → v7.5.0.
    • Package/library version updated to 3.9.0.

Inaction and NestedObject support
@coderabbitai
Copy link

coderabbitai bot commented Feb 11, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds nested-property support for profiles and events across the JS example app and native Android bridge, updates date-conversion to recurse into nested structures, and bumps package and native SDK versions for release 3.9.0.

Changes

Cohort / File(s) Summary
Release & Metadata
package.json, CHANGELOG.md, android/build.gradle, clevertap-react-native.podspec
Bumps package/library to 3.9.0, increments Android versionCode to 390, and updates CleverTap Android SDK to 7.8.0 and iOS SDK to 7.5.0.
Core Library
src/index.js
Updates libVersion to 30900 and enhances convertDateToEpochInProperties to recursively convert Date objects inside nested objects and arrays.
Example App — Actions & UI
Example/app/constants.js, Example/app/App.js
Adds three new action identifiers for nested-property workflows and wires them into the app action handling / UI accordion.
Example App — Utilities
Example/app/app-utils.js
Adds three exported helper functions: set_userProfileWithNestedProperties, onUser_LoginWithNestedProperties, and recordEventWithNestedProperties that build nested payloads and call CleverTap APIs.
Native Android Bridge
android/src/main/java/.../CleverTapModuleImpl.java
Extends eventPropsFromReadableMap and profileFromReadableMap to handle ReadableType.Map and ReadableType.Array, converting nested maps/arrays to standard Map/Array structures with error logging.

Sequence Diagram(s)

mermaid
sequenceDiagram
participant ExampleApp as Example App (UI)
participant AppUtils as AppUtils (JS)
participant CoreLib as Core Lib (src/index.js)
participant NativeBridge as Native Bridge (CleverTapModuleImpl)
participant CleverTapSDK as CleverTap SDK

ExampleApp->>AppUtils: Trigger nested-property action
AppUtils->>CoreLib: Prepare payload (nested objects, Dates)
CoreLib->>CoreLib: convertDateToEpochInProperties (recursive)
CoreLib->>NativeBridge: send ReadableMap/Array payload
NativeBridge->>NativeBridge: Convert ReadableMap/Array -> Map/Array
NativeBridge->>CleverTapSDK: profileSet/onUserLogin/recordEvent with payload
CleverTapSDK-->>NativeBridge: ack/response
NativeBridge-->>CoreLib: result
CoreLib-->>ExampleApp: completion callback

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~22 minutes

Possibly related PRs

  • Release 3.3.0 #464: Similar release/version updates and libVersion changes in src/index.js.
  • Release v3.5.0 #476: Related bumps to changelog, native SDK versions, and build metadata.
  • Release 3.8.1 #491: Overlapping changes to android/build.gradle, podspec, package.json, and src/index.js.

Suggested reviewers

  • nishant-clevertap
  • CTLalit
  • piyush-kukadiya
  • darshanclevertap

Poem

🐰 I nested data in a cozy heap,
Dates turned epochs while I hopped to keep,
SDKs climbed versions, shiny and bright,
Profiles and events tucked in tight—
Hooray for 3.9.0! 🥕

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'task(SDK-5520) - Release v3.9.0' directly corresponds to the main objective of the PR, which is to release version 3.9.0 with support for inaction and nested object handling.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch task/SDK-5520/release_3.9.0

Tip

Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@francispereira
Copy link

francispereira commented Feb 11, 2026

Snyk checks have passed. No issues have been found so far.

Status Scanner Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues
Code Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@Anush-Shand
Copy link
Contributor Author

@coderabbitai review

@coderabbitai
Copy link

coderabbitai bot commented Feb 11, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
src/index.js (1)

253-262: ⚠️ Potential issue | 🟡 Minor

Date objects directly inside arrays won't be converted to epoch.

The array branch recurses into object elements via convertDateToEpochInProperties(item), but that function works on key-value entries of an object. If an array directly contains Date instances (e.g., [new Date(), new Date()]), Object.entries() on a Date yields nothing, so those dates won't be converted to the $D_ epoch format.

This is likely a rare edge case for CleverTap event properties, but worth noting. If direct Date array elements need conversion, the array iteration would need to check for Date instances explicitly and replace them in-place.

Proposed fix to also handle Date elements in arrays
             } else if (Array.isArray(value)) {
                 // Recursively convert dates in array elements
-                value.forEach(item => {
-                    if (item !== null && typeof item === 'object') {
+                value.forEach((item, index) => {
+                    if (Object.prototype.toString.call(item) === '[object Date]') {
+                        value[index] = "$D_" + Math.floor(item.getTime() / 1000);
+                    } else if (item !== null && typeof item === 'object') {
                         convertDateToEpochInProperties(item);
                     }
                 });
Example/app/App.js (1)

380-380: ⚠️ Potential issue | 🟡 Minor

Pre-existing: stray comma produces an undefined entry in the array.

Line 380 has a bare , which inserts an undefined element into the subCategory array under Product Config. This isn't introduced by this PR, but worth cleaning up to avoid unexpected rendering behavior in ExpandableListView.

Proposed fix
         { action: Actions.PRODUCT_CONFIG_GET_STRINGS, name: 'getStrings' },
         { action: Actions.PRODUCT_CONFIG_RESET, name: 'reset' },
-        ,
         {
           action: Actions.PRODUCT_CONFIG_LAST_FETCH_TS,

@Anush-Shand
Copy link
Contributor Author

@coderabbitai review

@coderabbitai
Copy link

coderabbitai bot commented Feb 11, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@Anush-Shand
Copy link
Contributor Author

@coderabbitai review

@coderabbitai
Copy link

coderabbitai bot commented Feb 16, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@Anush-Shand Anush-Shand merged commit 3d4a3d2 into develop Feb 17, 2026
4 checks passed
@Anush-Shand Anush-Shand deleted the task/SDK-5520/release_3.9.0 branch February 17, 2026 04:45
@coderabbitai coderabbitai bot mentioned this pull request Feb 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants