TP-52884 | Bump com.google.code.gson:gson from 2.10.1 to 2.11.0 in /android (#10924)
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Shivam Goyal <shivam.goyal@navi.com>
This commit is contained in:
@@ -80,7 +80,7 @@ android {
|
||||
debuggable false
|
||||
minifyEnabled true
|
||||
shrinkResources false
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro', 'retrofit2.pro', 'gson.pro', 'alfred.pro', 'courier.pro'
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro', 'retrofit2.pro', 'alfred.pro', 'courier.pro'
|
||||
matchingFallbacks = ['release']
|
||||
signingConfig signingConfigs.debug
|
||||
manifestPlaceholders = [branchMode: 'false']
|
||||
@@ -90,7 +90,7 @@ android {
|
||||
debuggable false
|
||||
minifyEnabled true
|
||||
shrinkResources false
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro', 'retrofit2.pro', 'gson.pro', 'alfred.pro', 'courier.pro'
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro', 'retrofit2.pro', 'alfred.pro', 'courier.pro'
|
||||
signingConfig signingConfigs.release
|
||||
manifestPlaceholders = [branchMode: 'false']
|
||||
matchingFallbacks = ['release']
|
||||
|
||||
@@ -1,72 +0,0 @@
|
||||
### Gson ProGuard and R8 rules which are relevant for all users
|
||||
### This file is automatically recognized by ProGuard and R8, see https://developer.android.com/build/shrink-code#configuration-files
|
||||
###
|
||||
### IMPORTANT:
|
||||
### - These rules are additive; don't include anything here which is not specific to Gson (such as completely
|
||||
### disabling obfuscation for all classes); the user would be unable to disable that then
|
||||
### - These rules are not complete; users will most likely have to add additional rules for their specific
|
||||
### classes, for example to disable obfuscation for certain fields or to keep no-args constructors
|
||||
###
|
||||
|
||||
# Keep generic signatures; needed for correct type resolution
|
||||
-keepattributes Signature
|
||||
|
||||
# Keep Gson annotations
|
||||
# Note: Cannot perform finer selection here to only cover Gson annotations, see also https://stackoverflow.com/q/47515093
|
||||
-keepattributes RuntimeVisibleAnnotations,AnnotationDefault
|
||||
|
||||
### The following rules are needed for R8 in "full mode" which only adheres to `-keepattribtues` if
|
||||
### the corresponding class or field is matches by a `-keep` rule as well, see
|
||||
### https://r8.googlesource.com/r8/+/refs/heads/main/compatibility-faq.md#r8-full-mode
|
||||
|
||||
# Keep class TypeToken (respectively its generic signature) if present
|
||||
-if class com.google.gson.reflect.TypeToken
|
||||
-keep,allowobfuscation class com.google.gson.reflect.TypeToken
|
||||
|
||||
# Keep any (anonymous) classes extending TypeToken
|
||||
-keep,allowobfuscation class * extends com.google.gson.reflect.TypeToken
|
||||
|
||||
# Keep classes with @JsonAdapter annotation
|
||||
-keep,allowobfuscation,allowoptimization @com.google.gson.annotations.JsonAdapter class *
|
||||
|
||||
# Keep fields with any other Gson annotation
|
||||
# Also allow obfuscation, assuming that users will additionally use @SerializedName or
|
||||
# other means to preserve the field names
|
||||
-keepclassmembers,allowobfuscation class * {
|
||||
@com.google.gson.annotations.Expose <fields>;
|
||||
@com.google.gson.annotations.JsonAdapter <fields>;
|
||||
@com.google.gson.annotations.Since <fields>;
|
||||
@com.google.gson.annotations.Until <fields>;
|
||||
}
|
||||
|
||||
# Keep no-args constructor of classes which can be used with @JsonAdapter
|
||||
# By default their no-args constructor is invoked to create an adapter instance
|
||||
-keepclassmembers class * extends com.google.gson.TypeAdapter {
|
||||
<init>();
|
||||
}
|
||||
-keepclassmembers class * implements com.google.gson.TypeAdapterFactory {
|
||||
<init>();
|
||||
}
|
||||
-keepclassmembers class * implements com.google.gson.JsonSerializer {
|
||||
<init>();
|
||||
}
|
||||
-keepclassmembers class * implements com.google.gson.JsonDeserializer {
|
||||
<init>();
|
||||
}
|
||||
|
||||
# Keep fields annotated with @SerializedName for classes which are referenced.
|
||||
# If classes with fields annotated with @SerializedName have a no-args
|
||||
# constructor keep that as well. Based on
|
||||
# https://issuetracker.google.com/issues/150189783#comment11.
|
||||
# See also https://github.com/google/gson/pull/2420#discussion_r1241813541
|
||||
# for a more detailed explanation.
|
||||
-if class *
|
||||
-keepclasseswithmembers,allowobfuscation class <1> {
|
||||
@com.google.gson.annotations.SerializedName <fields>;
|
||||
}
|
||||
-if class * {
|
||||
@com.google.gson.annotations.SerializedName <fields>;
|
||||
}
|
||||
-keepclassmembers,allowobfuscation,allowoptimization class <1> {
|
||||
<init>();
|
||||
}
|
||||
@@ -72,7 +72,6 @@ import com.navi.common.juspay.HyperServicesHolder
|
||||
import com.navi.common.model.ModuleNameV2
|
||||
import com.navi.common.network.models.GenericErrorResponse
|
||||
import com.navi.common.uitron.model.action.UploadDataConfig
|
||||
import com.navi.common.uitron.serializer.AnySerializer
|
||||
import com.navi.common.uitron.serializer.UiTronActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronTriggerApiActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronUploadDataSerializer
|
||||
@@ -1013,7 +1012,6 @@ fun naviAppSerializerGsonBuilder(): Gson =
|
||||
VisualTransformationData::class.java,
|
||||
VisualTransformationDataSerializer()
|
||||
)
|
||||
.registerTypeAdapter(Any::class.java, AnySerializer())
|
||||
.create()
|
||||
|
||||
fun buildUrlWithParameters(
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
*
|
||||
* * Copyright © 2023 by Navi Technologies Limited
|
||||
* * Copyright © 2023-2024 by Navi Technologies Limited
|
||||
* * All rights reserved. Strictly confidential
|
||||
*
|
||||
*/
|
||||
@@ -24,7 +24,6 @@ import com.navi.common.network.converter.EmptyBodyHandlingConverterFactory
|
||||
import com.navi.common.uitron.model.LambdaEventData
|
||||
import com.navi.common.uitron.model.action.ThirdPartySdkAction
|
||||
import com.navi.common.uitron.model.action.UploadDataConfig
|
||||
import com.navi.common.uitron.serializer.AnySerializer
|
||||
import com.navi.common.uitron.serializer.UiTronSDKActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronTriggerApiActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronUploadDataSerializer
|
||||
@@ -80,7 +79,6 @@ object APNetworkModule {
|
||||
VisualTransformationDataSerializer()
|
||||
)
|
||||
.registerTypeAdapter(ThirdPartySdkAction::class.java, UiTronSDKActionSerializer())
|
||||
.registerTypeAdapter(Any::class.java, AnySerializer())
|
||||
.registerTypeAdapter(LambdaEventData::class.java, LambdaEventSerializer())
|
||||
.create()
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@ firebase-perf = "1.4.2"
|
||||
glide = "4.14.2"
|
||||
gojek-courier = "0.2.9"
|
||||
google-services = "4.4.0"
|
||||
gson = "2.10.1"
|
||||
gson = "2.11.0"
|
||||
hamcrest = "2.2"
|
||||
hilt = "2.48"
|
||||
hms = "2.9.0"
|
||||
@@ -92,10 +92,10 @@ moengage-android-sdk = "12.6.02"
|
||||
moengage-inapp = "6.5.0"
|
||||
moengage-push-amp-plus = "6.2.1"
|
||||
moengage-rich-notification = "4.3.2"
|
||||
navi-alfred = "1.7.1"
|
||||
navi-guarddog = "3.0.2"
|
||||
navi-pulse = "1.3.1"
|
||||
navi-uitron = "1.10.1"
|
||||
navi-alfred = "1.8.0"
|
||||
navi-guarddog = "3.1.0"
|
||||
navi-pulse = "1.4.0"
|
||||
navi-uitron = "1.12.0"
|
||||
navigation = "2.5.3"
|
||||
okhttp-bom = "4.12.0"
|
||||
otaliastudios-cameraview = "2.7.2"
|
||||
|
||||
@@ -1,24 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* * Copyright © 2024 by Navi Technologies Limited
|
||||
* * All rights reserved. Strictly confidential
|
||||
*
|
||||
*/
|
||||
|
||||
package com.navi.common.uitron.serializer
|
||||
|
||||
import com.google.gson.JsonElement
|
||||
import com.google.gson.JsonPrimitive
|
||||
import com.google.gson.JsonSerializationContext
|
||||
import com.google.gson.JsonSerializer
|
||||
import java.lang.reflect.Type
|
||||
|
||||
class AnySerializer : JsonSerializer<Any> {
|
||||
override fun serialize(
|
||||
src: Any?,
|
||||
typeOfSrc: Type?,
|
||||
context: JsonSerializationContext?
|
||||
): JsonElement {
|
||||
return JsonPrimitive(src?.toString())
|
||||
}
|
||||
}
|
||||
@@ -56,7 +56,6 @@ import com.navi.common.uitron.deserializer.UiTronUploadDataDeserializer
|
||||
import com.navi.common.uitron.model.action.LaunchIntentAction
|
||||
import com.navi.common.uitron.model.action.ThirdPartySdkAction
|
||||
import com.navi.common.uitron.model.action.UploadDataConfig
|
||||
import com.navi.common.uitron.serializer.AnySerializer
|
||||
import com.navi.common.uitron.serializer.UiTronActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronSDKActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronTriggerApiActionSerializer
|
||||
@@ -350,7 +349,6 @@ fun GsonBuilder.registerUiTronSerializer(): GsonBuilder {
|
||||
VisualTransformationDataSerializer()
|
||||
)
|
||||
registerTypeAdapter(ThirdPartySdkAction::class.java, UiTronSDKActionSerializer())
|
||||
registerTypeAdapter(Any::class.java, AnySerializer())
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -11,7 +11,6 @@ import com.google.gson.Gson
|
||||
import com.google.gson.GsonBuilder
|
||||
import com.navi.common.uitron.model.action.ThirdPartySdkAction
|
||||
import com.navi.common.uitron.model.action.UploadDataConfig
|
||||
import com.navi.common.uitron.serializer.AnySerializer
|
||||
import com.navi.common.uitron.serializer.UiTronActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronSDKActionSerializer
|
||||
import com.navi.common.uitron.serializer.UiTronTriggerApiActionSerializer
|
||||
@@ -61,7 +60,6 @@ private fun GsonBuilder.registerRRUiTronSerializers(): GsonBuilder {
|
||||
)
|
||||
registerTypeAdapter(ThirdPartySdkAction::class.java, UiTronSDKActionSerializer())
|
||||
registerTypeAdapter(UiTronData::class.java, RRComposeDataSerializer())
|
||||
registerTypeAdapter(Any::class.java, AnySerializer())
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user