From 8788e1d81ace4095ffeaa47d6459a43a6d755ab8 Mon Sep 17 00:00:00 2001 From: uerceg Date: Thu, 28 Mar 2024 10:52:24 +0100 Subject: [PATCH 1/3] feat: update version number to 4.38.0 --- README.md | 2 +- VERSION | 2 +- android/build.gradle | 2 +- ios/adjust_sdk.podspec | 4 ++-- lib/adjust.dart | 2 +- pubspec.yaml | 2 +- test/ios/test_lib.podspec | 2 +- test/pubspec.yaml | 2 +- 8 files changed, 9 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index fc27c7e..3fd8291 100644 --- a/README.md +++ b/README.md @@ -104,7 +104,7 @@ You can add Adjust SDK to your Flutter app by adding following to your `pubspec. ```yaml dependencies: - adjust_sdk: ^4.37.1 + adjust_sdk: ^4.38.0 ``` Then navigate to your project in the terminal and run: diff --git a/VERSION b/VERSION index bc9fffb..fff125e 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -4.37.1 +4.38.0 diff --git a/android/build.gradle b/android/build.gradle index c415465..dd06511 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -37,5 +37,5 @@ android { } dependencies { - api 'com.adjust.sdk:adjust-android:4.38.1' + api 'com.adjust.sdk:adjust-android:4.38.3' } diff --git a/ios/adjust_sdk.podspec b/ios/adjust_sdk.podspec index 04ecc51..32e7996 100644 --- a/ios/adjust_sdk.podspec +++ b/ios/adjust_sdk.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'adjust_sdk' - s.version = '4.37.1' + s.version = '4.38.0' s.summary = 'Adjust Flutter SDK for iOS platform' s.description = <<-DESC Adjust Flutter SDK for iOS platform. @@ -14,5 +14,5 @@ Pod::Spec.new do |s| s.ios.deployment_target = '8.0' s.dependency 'Flutter' - s.dependency 'Adjust', '4.37.1' + s.dependency 'Adjust', '4.38.0' end diff --git a/lib/adjust.dart b/lib/adjust.dart index 7cbde3f..42f2e55 100644 --- a/lib/adjust.dart +++ b/lib/adjust.dart @@ -23,7 +23,7 @@ import 'package:flutter/services.dart'; import 'package:meta/meta.dart'; class Adjust { - static const String _sdkPrefix = 'flutter4.37.1'; + static const String _sdkPrefix = 'flutter4.38.0'; static const MethodChannel _channel = const MethodChannel('com.adjust.sdk/api'); diff --git a/pubspec.yaml b/pubspec.yaml index b78519a..372b0b1 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,7 +1,7 @@ name: adjust_sdk description: This is the Flutter SDK of Adjust™. You can read more about Adjust™ at adjust.com. homepage: https://github.com/adjust/flutter_sdk -version: 4.37.1 +version: 4.38.0 environment: sdk: ">=2.12.0 <3.0.0" diff --git a/test/ios/test_lib.podspec b/test/ios/test_lib.podspec index 7daf4e0..292391d 100644 --- a/test/ios/test_lib.podspec +++ b/test/ios/test_lib.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'test_lib' - s.version = '4.37.1' + s.version = '4.38.0' s.summary = 'Adjust test library for iOS platform' s.description = <<-DESC Adjust test library for iOS platform. diff --git a/test/pubspec.yaml b/test/pubspec.yaml index 0ca4f72..34f625a 100644 --- a/test/pubspec.yaml +++ b/test/pubspec.yaml @@ -1,6 +1,6 @@ name: test_lib description: Flutter plugin for Adjust Testing Library. Intended exclusively for internal use. -version: 4.37.1 +version: 4.38.0 author: Adjust (sdk@adjust.com) environment: From c39c1132aa3335248281354339ec798e81573698 Mon Sep 17 00:00:00 2001 From: uerceg Date: Thu, 28 Mar 2024 13:10:47 +0100 Subject: [PATCH 2/3] test: update testing flow --- ios/Classes/AdjustSdk.m | 26 ++++++------- test/app/lib/command.dart | 2 +- test/app/lib/command_executor.dart | 60 ++++++++++++++++++------------ test/app/lib/main.dart | 21 +++-------- 4 files changed, 54 insertions(+), 55 deletions(-) diff --git a/ios/Classes/AdjustSdk.m b/ios/Classes/AdjustSdk.m index a54662e..ad2d031 100644 --- a/ios/Classes/AdjustSdk.m +++ b/ios/Classes/AdjustSdk.m @@ -829,10 +829,7 @@ - (void)processDeeplink:(FlutterMethodCall *)call withResult:(FlutterResult)resu - (void)setTestOptions:(FlutterMethodCall *)call withResult:(FlutterResult)result { AdjustTestOptions *testOptions = [[AdjustTestOptions alloc] init]; - NSString *baseUrl = call.arguments[@"baseUrl"]; - NSString *gdprUrl = call.arguments[@"gdprUrl"]; - NSString *subscriptionUrl = call.arguments[@"subscriptionUrl"]; - NSString *purchaseVerificationUrl = call.arguments[@"purchaseVerificationUrl"]; + NSString *overwriteUrl = call.arguments[@"urlOverwrite"]; NSString *extraPath = call.arguments[@"extraPath"]; NSString *timerIntervalInMilliseconds = call.arguments[@"timerIntervalInMilliseconds"]; NSString *timerStartInMilliseconds = call.arguments[@"timerStartInMilliseconds"]; @@ -842,18 +839,11 @@ - (void)setTestOptions:(FlutterMethodCall *)call withResult:(FlutterResult)resul NSString *deleteState = call.arguments[@"deleteState"]; NSString *noBackoffWait = call.arguments[@"noBackoffWait"]; NSString *adServicesFrameworkEnabled = call.arguments[@"adServicesFrameworkEnabled"]; + NSString *attStatus = call.arguments[@"attStatus"]; + NSString *idfa = call.arguments[@"idfa"]; - if ([self isFieldValid:baseUrl]) { - testOptions.baseUrl = baseUrl; - } - if ([self isFieldValid:gdprUrl]) { - testOptions.gdprUrl = gdprUrl; - } - if ([self isFieldValid:subscriptionUrl]) { - testOptions.subscriptionUrl = subscriptionUrl; - } - if ([self isFieldValid:purchaseVerificationUrl]) { - testOptions.purchaseVerificationUrl = purchaseVerificationUrl; + if ([self isFieldValid:overwriteUrl]) { + testOptions.urlOverwrite = overwriteUrl; } if ([self isFieldValid:extraPath]) { testOptions.extraPath = extraPath; @@ -885,6 +875,12 @@ - (void)setTestOptions:(FlutterMethodCall *)call withResult:(FlutterResult)resul if ([self isFieldValid:adServicesFrameworkEnabled]) { testOptions.adServicesFrameworkEnabled = [adServicesFrameworkEnabled boolValue]; } + if ([self isFieldValid:attStatus]) { + testOptions.attStatusInt = [NSNumber numberWithInt:[attStatus intValue]]; + } + if ([self isFieldValid:idfa]) { + testOptions.idfa = idfa; + } [Adjust setTestOptions:testOptions]; } diff --git a/test/app/lib/command.dart b/test/app/lib/command.dart index 1e58a09..93d255a 100644 --- a/test/app/lib/command.dart +++ b/test/app/lib/command.dart @@ -3,7 +3,7 @@ // Adjust SDK // // Created by Srdjan Tubin (@2beens) on 25th April 2018. -// Copyright (c) 2018-2021 Adjust GmbH. All rights reserved. +// Copyright (c) 2018-Present Adjust GmbH. All rights reserved. // import 'dart:convert'; diff --git a/test/app/lib/command_executor.dart b/test/app/lib/command_executor.dart index 3ab8dc6..05b89f6 100644 --- a/test/app/lib/command_executor.dart +++ b/test/app/lib/command_executor.dart @@ -3,7 +3,7 @@ // Adjust SDK // // Created by Srdjan Tubin (@2beens) on 25th April 2018. -// Copyright (c) 2018-2021 Adjust GmbH. All rights reserved. +// Copyright (c) 2018-Present Adjust GmbH. All rights reserved. // import 'dart:io' show Platform; @@ -35,20 +35,18 @@ class CommandExecutor { String? _subscriptionPath; String? _purchaseVerificationUrl; String? _purchaseVerificationPath; + String? _overwriteUrl; String? _extraPath; late Command _command; Map _savedEvents = new Map(); Map _savedConfigs = new Map(); - CommandExecutor( - String? baseUrl, - String? gdprUrl, - String? subscriptionUrl, - String? purchaseVerificationUrl) { - _baseUrl = baseUrl; - _gdprUrl = gdprUrl; - _subscriptionUrl = subscriptionUrl; - _purchaseVerificationUrl = purchaseVerificationUrl; + CommandExecutor(String? overwriteUrl) { + _baseUrl = overwriteUrl; + _gdprUrl = overwriteUrl; + _subscriptionUrl = overwriteUrl; + _purchaseVerificationUrl = overwriteUrl; + _overwriteUrl = overwriteUrl; } void executeCommand(Command command) { @@ -149,10 +147,11 @@ class CommandExecutor { void _testOptions() { final dynamic testOptions = {}; - testOptions['baseUrl'] = _baseUrl; - testOptions['gdprUrl'] = _gdprUrl; - testOptions['subscriptionUrl'] = _subscriptionUrl; - testOptions['purchaseVerificationUrl'] = _purchaseVerificationUrl; + testOptions['baseUrl'] = _overwriteUrl; + testOptions['gdprUrl'] = _overwriteUrl; + testOptions['subscriptionUrl'] = _overwriteUrl; + testOptions['purchaseVerificationUrl'] = _overwriteUrl; + testOptions['urlOverwrite'] = _overwriteUrl; if (_command.containsParameter('basePath')) { _basePath = _command.getFirstParameterValue('basePath'); _gdprPath = _command.getFirstParameterValue('basePath'); @@ -188,16 +187,24 @@ class CommandExecutor { testOptions['adServicesFrameworkEnabled'] = _command.getFirstParameterValue('adServicesFrameworkEnabled'); } + if (_command.containsParameter('attStatus')) { + testOptions['attStatus'] = + _command.getFirstParameterValue('attStatus'); + } + if (_command.containsParameter('idfa')) { + testOptions['idfa'] = + _command.getFirstParameterValue('idfa'); + } bool useTestConnectionOptions = false; if (_command.containsParameter('teardown')) { List teardownOptions = _command.getParamteters('teardown')!; for (String teardownOption in teardownOptions) { if (teardownOption == 'resetSdk') { testOptions['teardown'] = 'true'; - testOptions['basePath'] = _basePath; - testOptions['gdprPath'] = _gdprPath; - testOptions['subscriptionPath'] = _subscriptionPath; - testOptions['purchaseVerificationPath'] = _purchaseVerificationPath; + testOptions['basePath'] = _extraPath; + testOptions['gdprPath'] = _extraPath; + testOptions['subscriptionPath'] = _extraPath; + testOptions['purchaseVerificationPath'] = _extraPath; testOptions['extraPath'] = _extraPath; // Android specific testOptions['useTestConnectionOptions'] = 'true'; @@ -376,6 +383,11 @@ class CommandExecutor { adjustConfig!.userAgent = _command.getFirstParameterValue('userAgent'); } + if (_command.containsParameter('attConsentWaitingSeconds')) { + adjustConfig!.attConsentWaitingInterval = + double.parse(_command.getFirstParameterValue('attConsentWaitingSeconds')!); + } + // First clear all previous callback handlers. adjustConfig!.attributionCallback = null; adjustConfig.sessionSuccessCallback = null; @@ -387,7 +399,7 @@ class CommandExecutor { // TODO: Deeplinking in Flutter example. // https://github.com/flutter/flutter/issues/8711#issuecomment-304681212 if (_command.containsParameter('deferredDeeplinkCallback')) { - String? localBasePath = _basePath; + String? localBasePath = _extraPath; adjustConfig.launchDeferredDeeplink = _command.getFirstParameterValue('deferredDeeplinkCallback') == 'true'; print( @@ -400,7 +412,7 @@ class CommandExecutor { } if (_command.containsParameter('attributionCallbackSendAll')) { - String? localBasePath = _basePath; + String? localBasePath = _extraPath; adjustConfig.attributionCallback = (AdjustAttribution attribution) { print('[CommandExecutor]: Attribution Callback: $attribution'); TestLib.addInfoToSend('trackerToken', attribution.trackerToken); @@ -420,7 +432,7 @@ class CommandExecutor { } if (_command.containsParameter('sessionCallbackSendSuccess')) { - String? localBasePath = _basePath; + String? localBasePath = _extraPath; adjustConfig.sessionSuccessCallback = (AdjustSessionSuccess sessionSuccessResponseData) { print( @@ -438,7 +450,7 @@ class CommandExecutor { } if (_command.containsParameter('sessionCallbackSendFailure')) { - String? localBasePath = _basePath; + String? localBasePath = _extraPath; adjustConfig.sessionFailureCallback = (AdjustSessionFailure sessionFailureResponseData) { print( @@ -458,7 +470,7 @@ class CommandExecutor { } if (_command.containsParameter('eventCallbackSendSuccess')) { - String? localBasePath = _basePath; + String? localBasePath = _extraPath; adjustConfig.eventSuccessCallback = (AdjustEventSuccess eventSuccessResponseData) { print( @@ -479,7 +491,7 @@ class CommandExecutor { } if (_command.containsParameter('eventCallbackSendFailure')) { - String? localBasePath = _basePath; + String? localBasePath = _extraPath; adjustConfig.eventFailureCallback = (AdjustEventFailure eventFailureResponseData) { print( diff --git a/test/app/lib/main.dart b/test/app/lib/main.dart index 1261ecf..6a5c151 100644 --- a/test/app/lib/main.dart +++ b/test/app/lib/main.dart @@ -17,10 +17,7 @@ class MyApp extends StatefulWidget { } class _MyAppState extends State { - String? _baseUrl; - String? _gdprUrl; - String? _subscriptionUrl; - String? _purchaseVerificationUrl; + String? _overwriteUrl; late String _controlUrl; late CommandExecutor _commandExecutor; @@ -28,28 +25,22 @@ class _MyAppState extends State { void initState() { super.initState(); - String _address = '192.168.86.21'; + String _address = '192.168.86.53'; if (Platform.isAndroid) { String _protocol = 'https'; String _port = '8443'; - _baseUrl = _protocol + '://' + _address + ':' + _port; - _gdprUrl = _protocol + '://' + _address + ':' + _port; - _subscriptionUrl = _protocol + '://' + _address + ':' + _port; - _purchaseVerificationUrl = _protocol + '://' + _address + ':' + _port; + _overwriteUrl = _protocol + '://' + _address + ':' + _port; _controlUrl = 'ws://' + _address + ':1987'; } else { String _protocol = 'http'; String _port = '8080'; - _baseUrl = _protocol + '://' + _address + ':' + _port; - _gdprUrl = _protocol + '://' + _address + ':' + _port; - _subscriptionUrl = _protocol + '://' + _address + ':' + _port; - _purchaseVerificationUrl = _protocol + '://' + _address + ':' + _port; + _overwriteUrl = _protocol + '://' + _address + ':' + _port; _controlUrl = 'ws://' + _address + ':1987'; } // Initialise command executor. _commandExecutor = - new CommandExecutor(_baseUrl, _gdprUrl, _subscriptionUrl, _purchaseVerificationUrl); + new CommandExecutor(_overwriteUrl); // Initialise test library. TestLib.setExecuteCommandHalder((final dynamic callArgs) { @@ -59,7 +50,7 @@ class _MyAppState extends State { '[AdjustTestApp]: Executing command ${command.className}.${command.methodName}'); _commandExecutor.executeCommand(command); }); - TestLib.init(_baseUrl!, _controlUrl); + TestLib.init(_overwriteUrl!, _controlUrl); } @override From 4e92de174744f98aec2d0db402c6319fee1b3b15 Mon Sep 17 00:00:00 2001 From: uerceg Date: Thu, 28 Mar 2024 13:11:56 +0100 Subject: [PATCH 3/3] docs: update changelog --- CHANGELOG.md | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 499cc9b..4b1e669 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,16 @@ +### Version 4.38.0 (28th March 2024) +#### Added +- Added iOS Privacy Manifest for the Adjust SDK. +- Added new domains and corresponding payload restrictions for the Adjust SDK to direct the iOS traffic to: + - https://consent.adjust.com - for consented users + - https://analytics.adjust.com - for non-consented users + +#### Native SDKs +- [iOS@v4.38.0][ios_sdk_v4.38.0] +- [Android@v4.38.3][android_sdk_v4.38.3] + +--- + ### Version 4.37.1 (21st February 2024) #### Added - Added support for `TradPlus` ad revenue tracking. @@ -412,6 +425,7 @@ [ios_sdk_v4.36.0]: https://github.com/adjust/ios_sdk/tree/v4.36.0 [ios_sdk_v4.37.0]: https://github.com/adjust/ios_sdk/tree/v4.37.0 [ios_sdk_v4.37.1]: https://github.com/adjust/ios_sdk/tree/v4.37.1 +[ios_sdk_v4.38.0]: https://github.com/adjust/ios_sdk/tree/v4.38.0 [android_sdk_v4.17.0]: https://github.com/adjust/android_sdk/tree/v4.17.0 [android_sdk_v4.18.0]: https://github.com/adjust/android_sdk/tree/v4.18.0 @@ -433,4 +447,5 @@ [android_sdk_v4.35.1]: https://github.com/adjust/android_sdk/tree/v4.35.1 [android_sdk_v4.37.0]: https://github.com/adjust/android_sdk/tree/v4.37.0 [android_sdk_v4.38.0]: https://github.com/adjust/android_sdk/tree/v4.38.0 -[android_sdk_v4.38.1]: https://github.com/adjust/android_sdk/tree/v4.38.1 \ No newline at end of file +[android_sdk_v4.38.1]: https://github.com/adjust/android_sdk/tree/v4.38.1 +[android_sdk_v4.38.3]: https://github.com/adjust/android_sdk/tree/v4.38.3 \ No newline at end of file