This article is a solution to the problems encountered by [Fast Leopard Life] when accessing Alibaichuuan SDK and upgrading Gradle

Hope to access ali Baichuan SDK taobao customers a little help

Environment:

1. The android studio 2

2. Gradle 6.7.1

3. Gradle tool 2

1. Obtain security pictures

1.1 Initialization error, the code is 203

JPG file. Change it to Yw_1222_baichuan.jpg and put it in RES /drawable

1.2 The name is confirmed correctly, and the security picture is the same as apK’s signature, still report 203

Close the resource optimization, in gradle. Add android properties. EnableResourceOptimizations = false

 

2. After upgrading Gradle, rebuild and report that the SDK of Baekawa is not found

Download the NOT Found AAR and JAR from the repository and put it in the LIBS

The final dependencies configuration

implementation fileTree(dir: ‘libs’, include: [‘*.jar’])

/ / alipay
implementation 'com. Ali. Auth. SDK: alibabauth_core: 2.0.0.6 @ aar'
implementation 'com. Ali. Auth. SDK: alibabauth_ui: 2.0.0.6 @ aar'
implementation 'com. Ali. Auth. SDK: alibabauth_ext: 2.0.0.6 @ aar'

// Security component
implementation(name: 'securityguardaar3'.version: "5.4.200".ext: 'aar')
implementation(name: 'securitybodyaar3'.version: "5.4.200".ext: 'aar')
implementation(name: 'avmpaar3'.version: "5.4.200".ext: 'aar')
implementation(name: 'sgmiddletieraar3'.version: "5.4.200".ext: 'aar')
//Mtop
// implementation(name: 'mtopsdk_allinone_open', version: "3.1.7.2", ext: 'jar')
//applink
implementation(name: 'alibc_link_partner'.version: "4.1.23".ext: 'aar')
//ut (jar package remote dependency)
implementation 'com. Taobao. Android: utdid4all: 1.5.2'
implementation 'com. Alibaba. MTL: app - monitor - SDK: 2.6.4.5 _for_bc'
// E-commerce infrastructure components
implementation 'com. Alibaba. SDK. The android: AlibcTradeCommon: 4.0.0.16 @ aar'
implementation 'com. Alibaba. SDK. The android: AlibcTradeBiz: 4.0.0.16 @ aar'
implementation 'com. Alibaba. SDK. The android: nb_trade: 4.0.0.16 @ aar'

implementation 'com. Alibaba: fastjson: 1.2.75'
Copy the code