From c38d50e9059add72d2f142ca761a0010456b7a26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Herculano?= Date: Tue, 22 Oct 2024 21:11:30 +0200 Subject: [PATCH 1/5] release 7.11.0 --- README.md | 2 +- cmplibrary/gradle.properties | 2 +- cmplibrary/release_note.txt | 3 ++- samples/nat-message-demo/build.gradle | 2 +- samples/web-message-demo/build.gradle | 2 +- 5 files changed, 6 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 5c05fb48a..844073d86 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ To use `cmplibrary` in your app, include `com.sourcepoint.cmplibrary:cmplibrary: ``` ... dependencies { - implementation 'com.sourcepoint.cmplibrary:cmplibrary:7.11.0-rc2-rc1' + implementation 'com.sourcepoint.cmplibrary:cmplibrary:7.11.0' } ``` diff --git a/cmplibrary/gradle.properties b/cmplibrary/gradle.properties index 892ffd18f..e57fc3507 100644 --- a/cmplibrary/gradle.properties +++ b/cmplibrary/gradle.properties @@ -1,4 +1,4 @@ -VERSION_NAME = 7.11.0-rc2 +VERSION_NAME = 7.11.0 POM_NAME = cmplibrary POM_REPO = sourcepoint diff --git a/cmplibrary/release_note.txt b/cmplibrary/release_note.txt index 3d33a07f4..50f532d10 100644 --- a/cmplibrary/release_note.txt +++ b/cmplibrary/release_note.txt @@ -1,4 +1,5 @@ * [DIA-4611](https://sourcepoint.atlassian.net/browse/DIA-4611) Refactor `customConsentGDPR` and `deleteCustomConsentTo` to use `mobile-core`'s implementation. [#836](https://github.com/SourcePointUSA/android-cmp-app/pull/836) -* Updated project dependencies and bump `minSdk` support from 21 to 23 due to [Android's new Security policy](https://developer.android.com/about/versions/14/behavior-changes-all#security) [#840](https://github.com/SourcePointUSA/android-cmp-app/pull/831) +* Updated project dependencies and bump `minSdk` support from 21 to 23 due to [Android's new Security policy](https://developer.android.com/about/versions/14/behavior-changes-all#security) [#840](https://github.com/SourcePointUSA/android-cmp-app/pull/840) +* Fixed an issue preventing the SDK from integrating with projects using KTor 3 [#840](https://github.com/SourcePointUSA/android-cmp-app/pull/840) * Bump `compileSdk` and `targetSdk` to 35 * Fixed an issue preventing the MetaApp from being released at Google Play diff --git a/samples/nat-message-demo/build.gradle b/samples/nat-message-demo/build.gradle index e3813a067..44802bc1f 100644 --- a/samples/nat-message-demo/build.gradle +++ b/samples/nat-message-demo/build.gradle @@ -77,5 +77,5 @@ dependencies { implementation 'androidx.appcompat:appcompat:1.7.0' implementation 'androidx.constraintlayout:constraintlayout:2.1.4' - implementation 'com.sourcepoint.cmplibrary:cmplibrary:7.11.0-rc2-rc1' + implementation 'com.sourcepoint.cmplibrary:cmplibrary:7.11.0-rc2' } diff --git a/samples/web-message-demo/build.gradle b/samples/web-message-demo/build.gradle index dbbc00cf1..750d23a6a 100644 --- a/samples/web-message-demo/build.gradle +++ b/samples/web-message-demo/build.gradle @@ -77,5 +77,5 @@ dependencies { implementation 'androidx.appcompat:appcompat:1.7.0' implementation 'androidx.constraintlayout:constraintlayout:2.1.4' - implementation 'com.sourcepoint.cmplibrary:cmplibrary:7.11.0-rc2-rc1' + implementation 'com.sourcepoint.cmplibrary:cmplibrary:7.11.0-rc2' } From f9c7814fae64f0819c04c6c3cd32e02dfa0552b9 Mon Sep 17 00:00:00 2001 From: andresilveirah Date: Tue, 22 Oct 2024 19:40:41 +0000 Subject: [PATCH 2/5] "committed files [/home/runner/work/android-cmp-app/android-cmp-app/samples/metaapp/gradle.properties]" --- samples/metaapp/gradle.properties | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/samples/metaapp/gradle.properties b/samples/metaapp/gradle.properties index d499642f3..17fdd586f 100644 --- a/samples/metaapp/gradle.properties +++ b/samples/metaapp/gradle.properties @@ -1,2 +1,2 @@ -#Fri Oct 18 13:24:03 UTC 2024 -VERSION_CODE=132 +#Tue Oct 22 19:35:42 UTC 2024 +VERSION_CODE=133 From cd25cd29cee3af99dc1877a37faf309ba550f875 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Herculano?= Date: Tue, 22 Oct 2024 21:48:30 +0200 Subject: [PATCH 3/5] release 7.11.0 --- .../campaign/CampaignManagerImplTest.kt | 2 - .../cmplibrary/campaign/CampaignManager.kt | 1 - .../cmplibrary/data/ServiceImpl.kt | 46 +++++++++++-------- .../network/converter/JsonConverterImpl.kt | 1 - .../model/optimized/MessagesApiModelExt.kt | 4 -- .../data/network/NetworkClientImplTest.kt | 2 - .../data/network/util/HttpUrlManagerTest.kt | 3 +- 7 files changed, 27 insertions(+), 32 deletions(-) diff --git a/cmplibrary/src/androidTest/java/com/sourcepoint/cmplibrary/campaign/CampaignManagerImplTest.kt b/cmplibrary/src/androidTest/java/com/sourcepoint/cmplibrary/campaign/CampaignManagerImplTest.kt index fa61ca85d..bb0afb3f1 100644 --- a/cmplibrary/src/androidTest/java/com/sourcepoint/cmplibrary/campaign/CampaignManagerImplTest.kt +++ b/cmplibrary/src/androidTest/java/com/sourcepoint/cmplibrary/campaign/CampaignManagerImplTest.kt @@ -7,8 +7,6 @@ import com.sourcepoint.cmplibrary.Utils.Companion.spEntries import com.sourcepoint.cmplibrary.Utils.Companion.storeTestDataObj import com.sourcepoint.cmplibrary.core.getOrNull import com.sourcepoint.cmplibrary.data.local.* //ktlint-disable -import com.sourcepoint.cmplibrary.data.network.converter.JsonConverter -import com.sourcepoint.cmplibrary.data.network.converter.converter import com.sourcepoint.cmplibrary.data.network.model.optimized.USNatConsentData import com.sourcepoint.cmplibrary.data.network.util.CampaignsEnv import com.sourcepoint.cmplibrary.exception.CampaignType diff --git a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/campaign/CampaignManager.kt b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/campaign/CampaignManager.kt index 877a18604..046db936f 100644 --- a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/campaign/CampaignManager.kt +++ b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/campaign/CampaignManager.kt @@ -30,7 +30,6 @@ import com.sourcepoint.mobile_core.network.responses.MetaDataResponse import kotlinx.serialization.encodeToString import kotlinx.serialization.json.JsonElement import kotlinx.serialization.json.JsonObject -import kotlinx.serialization.json.jsonObject import org.json.JSONObject import java.text.SimpleDateFormat import java.time.Instant diff --git a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/ServiceImpl.kt b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/ServiceImpl.kt index 3b7529695..98c285fd5 100644 --- a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/ServiceImpl.kt +++ b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/ServiceImpl.kt @@ -731,26 +731,32 @@ internal class ServiceImpl( usNatApplies: Boolean?, ) { val statusMetadata = ConsentStatusRequest.MetaData( - gdpr = campaigns4Config.firstOrNull { it.campaignType == GDPR }?.let { ConsentStatusRequest.MetaData.Campaign( - applies = gdprApplies ?: false, - dateCreated = gdprConsentStatus?.dateCreated, - uuid = gdprConsentStatus?.uuid, - hasLocalData = false - ) }, - usnat = campaigns4Config.firstOrNull { it.campaignType == USNAT }?.let { ConsentStatusRequest.MetaData.USNatCampaign( - applies = usNatApplies ?: false, - dateCreated = transitionCCPAUSnatDateCreated, - uuid = usNatConsentData?.uuid, - hasLocalData = false, - transitionCCPAAuth = transitionCCPAAuth, - optedOut = transitionCCPAOptedOut - ) }, - ccpa = campaigns4Config.firstOrNull { it.campaignType == CCPA }?.let { ConsentStatusRequest.MetaData.Campaign( - applies = ccpaApplies ?: false, - dateCreated = ccpaConsentStatus?.dateCreated, - uuid = ccpaConsentStatus?.uuid, - hasLocalData = false, - ) } + gdpr = campaigns4Config.firstOrNull { it.campaignType == GDPR }?.let { + ConsentStatusRequest.MetaData.Campaign( + applies = gdprApplies ?: false, + dateCreated = gdprConsentStatus?.dateCreated, + uuid = gdprConsentStatus?.uuid, + hasLocalData = false + ) + }, + usnat = campaigns4Config.firstOrNull { it.campaignType == USNAT }?.let { + ConsentStatusRequest.MetaData.USNatCampaign( + applies = usNatApplies ?: false, + dateCreated = transitionCCPAUSnatDateCreated, + uuid = usNatConsentData?.uuid, + hasLocalData = false, + transitionCCPAAuth = transitionCCPAAuth, + optedOut = transitionCCPAOptedOut + ) + }, + ccpa = campaigns4Config.firstOrNull { it.campaignType == CCPA }?.let { + ConsentStatusRequest.MetaData.Campaign( + applies = ccpaApplies ?: false, + dateCreated = ccpaConsentStatus?.dateCreated, + uuid = ccpaConsentStatus?.uuid, + hasLocalData = false, + ) + } ) val response = getConsentStatus( authId = messageReq.authId, diff --git a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/converter/JsonConverterImpl.kt b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/converter/JsonConverterImpl.kt index 082b1a8b1..4ef76c951 100644 --- a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/converter/JsonConverterImpl.kt +++ b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/converter/JsonConverterImpl.kt @@ -13,7 +13,6 @@ import com.sourcepoint.cmplibrary.model.getMap import com.sourcepoint.cmplibrary.model.toTreeMap import com.sourcepoint.cmplibrary.util.check import kotlinx.serialization.json.Json -import kotlinx.serialization.json.JsonObject import kotlinx.serialization.json.jsonObject import org.json.JSONObject diff --git a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/model/optimized/MessagesApiModelExt.kt b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/model/optimized/MessagesApiModelExt.kt index 81bb8e0ad..bf600b71a 100644 --- a/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/model/optimized/MessagesApiModelExt.kt +++ b/cmplibrary/src/main/java/com/sourcepoint/cmplibrary/data/network/model/optimized/MessagesApiModelExt.kt @@ -1,15 +1,11 @@ package com.sourcepoint.cmplibrary.data.network.model.optimized -import com.sourcepoint.cmplibrary.campaign.CampaignManager import com.sourcepoint.cmplibrary.data.network.converter.JsonConverter import com.sourcepoint.cmplibrary.data.network.converter.converter -import com.sourcepoint.cmplibrary.data.network.model.optimized.includeData.buildIncludeData import com.sourcepoint.cmplibrary.data.network.model.optimized.messages.OperatingSystemInfoParam import com.sourcepoint.cmplibrary.data.network.util.CampaignsEnv import com.sourcepoint.cmplibrary.exception.CampaignType import com.sourcepoint.cmplibrary.model.CampaignReq -import com.sourcepoint.cmplibrary.util.extensions.getGppCustomOption -import kotlinx.serialization.encodeToString import kotlinx.serialization.json.* // ktlint-disable internal fun getMessageBody( diff --git a/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/NetworkClientImplTest.kt b/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/NetworkClientImplTest.kt index fb6169255..0a794a2ed 100644 --- a/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/NetworkClientImplTest.kt +++ b/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/NetworkClientImplTest.kt @@ -3,7 +3,6 @@ package com.sourcepoint.cmplibrary.data.network import com.sourcepoint.cmplibrary.assertEquals import com.sourcepoint.cmplibrary.core.Either import com.sourcepoint.cmplibrary.data.network.model.optimized.* // ktlint-disable -import com.sourcepoint.cmplibrary.data.network.model.optimized.includeData.buildIncludeData import com.sourcepoint.cmplibrary.data.network.util.Env import com.sourcepoint.cmplibrary.data.network.util.HttpUrlManagerSingleton import com.sourcepoint.cmplibrary.data.network.util.ResponseManager @@ -22,7 +21,6 @@ import okhttp3.Call import okhttp3.OkHttpClient import okhttp3.Request import okhttp3.Response -import org.json.JSONObject import org.junit.Assert.assertThrows import org.junit.Before import org.junit.Test diff --git a/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/util/HttpUrlManagerTest.kt b/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/util/HttpUrlManagerTest.kt index 97099c94b..389e525fe 100644 --- a/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/util/HttpUrlManagerTest.kt +++ b/cmplibrary/src/test/java/com/sourcepoint/cmplibrary/data/network/util/HttpUrlManagerTest.kt @@ -15,7 +15,6 @@ import com.sourcepoint.cmplibrary.model.PMTab import com.sourcepoint.cmplibrary.model.PmUrlConfig import com.sourcepoint.cmplibrary.model.exposed.ActionType import com.sourcepoint.cmplibrary.model.exposed.MessageType.* // ktlint-disable -import com.sourcepoint.cmplibrary.util.file2String import kotlinx.serialization.json.JsonObject import kotlinx.serialization.json.JsonPrimitive import org.json.JSONObject @@ -421,7 +420,7 @@ class HttpUrlManagerTest { sut.run { toString().contains("cdn.privacy-mgmt.com").assertTrue() queryParameter("env").assertEquals("prod") - queryParameter("nonKeyedLocalState")?.replace("\n","")?.replace(" ","").assertEquals("""{"_sp_v1_data":585620}""") + queryParameter("nonKeyedLocalState")?.replace("\n", "")?.replace(" ", "").assertEquals("""{"_sp_v1_data":585620}""") queryParameter("metadata").assertEquals("""{ "ccpa": { "applies": true }, "gdpr": { "applies": true }}""") queryParameter("scriptVersion").assertEquals(BuildConfig.VERSION_NAME) queryParameter("pubData").assertNull() From 2f5a72620224ba3afb11dc93bf716a7f3afd1ba8 Mon Sep 17 00:00:00 2001 From: andresilveirah Date: Tue, 22 Oct 2024 19:54:39 +0000 Subject: [PATCH 4/5] "committed files [/home/runner/work/android-cmp-app/android-cmp-app/samples/metaapp/gradle.properties]" --- samples/metaapp/gradle.properties | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/samples/metaapp/gradle.properties b/samples/metaapp/gradle.properties index 17fdd586f..3898836d8 100644 --- a/samples/metaapp/gradle.properties +++ b/samples/metaapp/gradle.properties @@ -1,2 +1,2 @@ -#Tue Oct 22 19:35:42 UTC 2024 -VERSION_CODE=133 +#Tue Oct 22 19:49:53 UTC 2024 +VERSION_CODE=134 From 363d623fc7961fbb55f91b9462ffd97ea79aa9bc Mon Sep 17 00:00:00 2001 From: andresilveirah Date: Tue, 22 Oct 2024 20:04:44 +0000 Subject: [PATCH 5/5] "committed files [/Users/runner/work/android-cmp-app/android-cmp-app/CHANGELOG.md, /Users/runner/work/android-cmp-app/android-cmp-app/README.md, /Users/runner/work/android-cmp-app/android-cmp-app/samples/web-message-demo/build.gradle, /Users/runner/work/android-cmp-app/android-cmp-app/samples/nat-message-demo/build.gradle]" --- CHANGELOG.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 69afcfa5e..e6854eb00 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## 7.11.0 (October, 22, 2024) +* [DIA-4611](https://sourcepoint.atlassian.net/browse/DIA-4611) Refactor `customConsentGDPR` and `deleteCustomConsentTo` to use `mobile-core`'s implementation. [#836](https://github.com/SourcePointUSA/android-cmp-app/pull/836) +* Updated project dependencies and bump `minSdk` support from 21 to 23 due to [Android's new Security policy](https://developer.android.com/about/versions/14/behavior-changes-all#security) [#840](https://github.com/SourcePointUSA/android-cmp-app/pull/840) +* Fixed an issue preventing the SDK from integrating with projects using KTor 3 [#840](https://github.com/SourcePointUSA/android-cmp-app/pull/840) +* Bump `compileSdk` and `targetSdk` to 35 +* Fixed an issue preventing the MetaApp from being released at Google Play + ## 7.11.0-rc2 (October, 18, 2024) * [DIA-4611](https://sourcepoint.atlassian.net/browse/DIA-4611) Refactor `customConsentGDPR` and `deleteCustomConsentTo` to use `mobile-core`'s implementation. [#836](https://github.com/SourcePointUSA/android-cmp-app/pull/836) * Updated project dependencies and bump `minSdk` support from 21 to 23 due to [Android's new Security policy](https://developer.android.com/about/versions/14/behavior-changes-all#security) [#840](https://github.com/SourcePointUSA/android-cmp-app/pull/831)