Skip to content
This repository was archived by the owner on Oct 29, 2024. It is now read-only.

Commit ae10a47

Browse files
LaunchDarklyReleaseBotbwoskow-ldtorchhoundorthancgwhelanLD
authored
prepare 6.2.0 release (#141)
* Removed the guides link * V4.0 (#68) * Update to iOS 5.4.0 (#48) * Bump iOS SDK version to 5.4.0 * Replace shared with get() * Replace old method names * Provide default values for EvaluationDetail * Fixed defaultValue for detail value * Changed individual nil coalesce to NSNull * Remove isDisableBackgroundPolling method (#52) * Update iOS base url (#49) * Update iOS base url * Added wrapper name and version to iOS and Android config (#50) * Added wrapper name and version to iOS and Android config * V4 not 5 * Rename wrapper * Add getVersion method (#51) * Added getVersion method * Revert package.json version bump * Fix version case Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Ben Woskow <[email protected]> * Rename fallback to defaultValue (#53) * Rename fallback to defaultValue * Fix awkward wording defaultValue value * Fix defaultValue value line breaks * Improved resiliency when running in Android (#54) * Add new config values (#55) * Added new config values to iOS and Android * Added typescript config * PR feedback * Fix millis, add default doc * fix common build + add tests for recent introductions (#56) * fix: start background thread for identify rather than running it (#66) * Bump Android SDK version to 2.14.1 (#59) * Update Android to 2.14.1, change setBaseUri to setPollUri, change floatVariation to doubleVariation * Fix float to double * Doublevalue on non detail * Run CI against v4.0 * URL fix iOS * Add isInitialized to iOS, check initialization in configure (#60) * Added isInitialized to iOS * Add init check to configure * Base url iOS fix, v4.0 ci * Var not func iOS, remove getMap * disable auto-alias in iOS (#61) * Add configureWithTimeout method (#58) * Added configureTimeout method * Fix timeout type on iOS * Simplify timeout nil check * Added param labels, Java syntax fixes * Small fixes * Make timeout final * Remove unnecessary catch * Fix baseUrl * Fix Android config error * Test against v4.0 hello branch * Fix tests * timeout never nil inside check * Convert Int to TimeInterval * Fixed iOS startWaitSeconds * Catch LDException * Fix merge conflict in iOS bridge * Fix merge conflict in index.js * PR feedback * Fix unused timeoutClient * Remove unnecessary ConfigEntryType * Remove StringSet * If let in timeout check * Configure method now takes optional timeout parameter instead of separate method * Renames for consistency (#62) * up-leveling the override for the default polling uri so it affects android too (#63) * Added ip, avatar, and allUserAttributesPrivate (#57) * Added ip, avatar, and allUserAttributesPrivate * Updated test-types.ts, fix case typo * Special case allUserAttributesPrivate * Fix ReadableMap loading of all private * CI fix * Fix string to URL baseUrl * Change to non-default values in test, combine lines in config.yml * Simplify allAttrsPrivate if * resolve breakage with latest merge Co-authored-by: Ben Woskow <[email protected]> * Added accessor methods for ConnectionInformation (#64) * Added ConnectionInformation accessors * Fixes from manual testing * PR feedback * Fix allUserAttributesPrivate * Improve typescript docs * Minor fixes (#66) Fixes `floatVariation` to keep double precision and fix build warnings. * Fix track metricValue on iOS (#67) * Remove CI checkout for release Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Ed Costello <[email protected]> Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Gavin Whelan <[email protected]> * Update iOS SDK dependency to fix Throttler behavior (#69) * V4.1.0 (#72) * Bump react native to 0.64 (#70) * Remove unnecessary React peer dependency (#71) * Fixed jsonVariationDetail parsing on Android and fixed a typo in jsonVariationDetailNone (#73) * Releasing version 4.0.2 * Removes Typescript enums and replaces them with types that extend string (#74) * Added ts flag for testing * Testing bwoskow typescript enum patch * Remove todo * Releasing version 4.0.3 * Multi Environment (#65) * Update to iOS 5.4.0 (#48) * Bump iOS SDK version to 5.4.0 * Replace shared with get() * Replace old method names * Provide default values for EvaluationDetail * Fixed defaultValue for detail value * Changed individual nil coalesce to NSNull * Remove isDisableBackgroundPolling method (#52) * Update iOS base url (#49) * Update iOS base url * Add protocol * Added wrapper name and version to iOS and Android config (#50) * Added wrapper name and version to iOS and Android config * V4 not 5 * Rename wrapper * Add getVersion method (#51) * Added getVersion method * Revert package.json version bump * Fix version case * Fix minor PR feedback * Update index.d.ts Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Ben Woskow <[email protected]> * Rename fallback to defaultValue (#53) * Rename fallback to defaultValue * Fix awkward wording defaultValue value * Fix defaultValue value line breaks * Improved resiliency when running in Android (#54) * Add new config values (#55) * Added new config values to iOS and Android * Added typescript config * PR feedback * Fix millis, add default doc * fix common build + add tests for recent introductions (#56) * Added secondaryMobileKeys and getForMobileKey * Added primaryEnvironmentName constant * Fix Android build errors * Fix build errors * Fix Android config error * CI test fixes * Catch LD exception without crashing * fix: start background thread for identify rather than running it (#66) * Bump Android SDK version to 2.14.1 (#59) * Update Android to 2.14.1, change setBaseUri to setPollUri, change floatVariation to doubleVariation * Fix float to double * Doublevalue on non detail * Run CI against v4.0 * URL fix iOS * Add isInitialized to iOS, check initialization in configure (#60) * Added isInitialized to iOS * Add init check to configure * Base url iOS fix, v4.0 ci * Var not func iOS, remove getMap * disable auto-alias in iOS (#61) * Add configureWithTimeout method (#58) * Added configureTimeout method * Fix timeout type on iOS * Simplify timeout nil check * Added param labels, Java syntax fixes * Small fixes * Make timeout final * Remove unnecessary catch * Fix baseUrl * Fix Android config error * Test against v4.0 hello branch * Fix tests * timeout never nil inside check * Convert Int to TimeInterval * Fixed iOS startWaitSeconds * Catch LDException * Fix merge conflict in iOS bridge * Fix merge conflict in index.js * PR feedback * Fix unused timeoutClient * Remove unnecessary ConfigEntryType * Remove StringSet * If let in timeout check * Configure method now takes optional timeout parameter instead of separate method * Renames for consistency (#62) * up-leveling the override for the default polling uri so it affects android too (#63) * Added ip, avatar, and allUserAttributesPrivate (#57) * Added ip, avatar, and allUserAttributesPrivate * Updated test-types.ts, fix case typo * Special case allUserAttributesPrivate * Fix ReadableMap loading of all private * CI fix * Fix string to URL baseUrl * Change to non-default values in test, combine lines in config.yml * Simplify allAttrsPrivate if * resolve breakage with latest merge Co-authored-by: Ben Woskow <[email protected]> * Multi environment works in Android, fixed bad config type * Fix allUserAttributesPrivate * Fix typescript test * No StringSet for wrapper, change to ldClient for isInitialized * Forgot nil check * environment param * Select environment via method parameter * Check for environment undefined in JS * iOS error fixes * Fix iOS bridge, add missing param and try to Android * Remove v4.0 branch hello rn for CI * Fixed all flags and better long conversion * A bunch of let to const, change default to test in multi env ts test, remove ldClient var from iOS * Remove internal comments from Android * Added back 2 Android comments, Double to NSNumber reversion, var to let reversion, ternary to function * Get default environment name from underlying SDKs * Cast NSNumber to Double to fix compilation error * getVersion public, remove ldClient from Android * Use get() * Remove unnecessary get() * Try instead of null check * as! Double to doubleValue, toIntExact to intValue, change Android env name, improve try * Fix listeners in multiple environments, change continue to comment in Android try/catch init * Add semicolon in between environment and flagKey or listenerId string concat * Environment concatenation function * Swift param labels * Added self, remove conditional cast to Any * Remove unnecessary nil coalescing * Capitalize ldClient * getForMobileKey Android * Removed unnecessary try, added final keyword * Revert some nonnull and Double types * Inline primaryEnvironmentName iOS Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Ben Woskow <[email protected]> * Add secondary user attribute (#76) * Fix multi environment on restwrapper (#77) * remove platform specific default env name * Replace function with ternary * Remove _getEnvironment * [ch109800] Await Android client initialization. (#78) Handle promise from `isInitialized` during configuration. Update iOS `isInitialized` to reject when not configured to match Android implementation. Improve Android `allFlags` to reject promise when non-existent environment is used or other exception, and allow calling `allFlags` before client initialization completes. * Update iOS method signature to match implementation (#79) * Releasing version 4.0.4 * [ch110474] Fixes for undeclared variables and other callback issues. (#81) * Changes for Android 3. (#82) * Add unit tests for JS native bridge wrapper. (#83) * Docs improvements (#84) * [ch94513] Add aliasing support (#85) * Requiring default values to be specified. Remove intVariation. (#86) * Safer and cleaner configuration on iOS (#87) * Cleanup Android variation implementation (#88) * Use latest iOS and Android SDKs (#89) * Fix issue with numeric variation calls. (#90) * Add consumer Proguard file to Android build configuration. (#91) * Update Android SDK to 3.1.1 (#92) * Fix for absolute paths in cocoapods generated build files by running pod install in CI. (#93) * Re-introduce compatibility for React Native 0.63 (#94) * Updates docs URLs * Add configuration option `inlineUsersInEvents` and typescript definition for `autoAliasingOptOut`. (#96) * minor doc improvement (#97) * Update version in README to match what version we'll actually be releasing with (#98) * Invert isOffline on iOS. (#99) * Fixes and improvements for CI configuration (#100) * [SC-130395] Allow native SDKs to generate anonymous user when user key is not provided. (#101) * See will this work without adding the mavenCentral * Adding MavenCentral * Fix RN0.63 builds * Fix outdated sed CI expression preventing actually testing against the current SDK version correctly (#103) * Update Android native SDK dependency and gradle config. (#104) * Update iOS SDK native dependency in podspec. (#105) * [sc-139041] Fix releaser typedoc generation (#106) * Have podspec retrieve version from package.json to allow using default releaser version script. (#107) * Fix iOS jsonVariation and jsonVariationDetail when using array default value. (#108) * Completely rework CI build to not use hello-react-native (#109) * Include manual testing application in repo (#110) * Adding the addListener and removeListeners method to silence the warning * Add privateAttributeNames to TypeScript and iOS wrapper implementation. (#112) * Bump to latest Android SDK release (#114) * Fix ownership handling for all flags and connection mode listeners on iOS. (#113) * Update iOS SDK to latest 5.4.5 release. (#115) * Update Android SDK to latest patch release. (#116) * Update to the correct variation method * Add RN 0.68 CI and expand RN version bounds in package definition. (#117) * Update supported RN versions in readme. * [sc-149512] Android reason fixes (#120) * Changes for iOS V6. (#122) * Use iOS 6.1.0 and new `LDUser.isAnonymousNullable` property (#123) * Fix automatically setting user as anonymous when both key and anonymous are unspecified (#124) Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Joe Cieslik <[email protected]> Co-authored-by: Ed Costello <[email protected]> Co-authored-by: Ben Woskow <[email protected]> Co-authored-by: Gavin Whelan <[email protected]> Co-authored-by: LaunchDarklyCI <[email protected]> Co-authored-by: LaunchDarklyReleaseBot <[email protected]> Co-authored-by: Ember Stevens <[email protected]> Co-authored-by: ember-stevens <[email protected]> Co-authored-by: Louis Chan <[email protected]> Co-authored-by: Louis Chan <[email protected]>
1 parent 8ef450e commit ae10a47

File tree

10 files changed

+667
-884
lines changed

10 files changed

+667
-884
lines changed

ManualTestApp/App.js

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { SafeAreaView,
1111
} from 'react-native';
1212
import { Picker } from '@react-native-picker/picker';
1313
import LDClient from 'launchdarkly-react-native-client-sdk';
14+
import MessageQueue from 'react-native/Libraries/BatchedBridge/MessageQueue.js';
1415

1516
const Wrapper = ({children}): Node => {
1617
const styles = {
@@ -62,14 +63,10 @@ const Body = () => {
6263
res = await client.boolVariation(flagKey, false);
6364
} else if (flagType === 'string') {
6465
res = await client.stringVariation(flagKey, '');
65-
} else if (flagType === 'int') {
66-
res = await client.numberVariation(flagKey, 0);
67-
} else if (flagType === 'float') {
66+
} else if (flagType === 'number') {
6867
res = await client.numberVariation(flagKey, 0.0);
69-
} else if (flagType === 'array') {
70-
res = await client.jsonVariation(flagKey, []);
71-
} else if (flagType === 'object') {
72-
res = await client.jsonVariation(flagKey, {});
68+
} else if (flagType === 'json') {
69+
res = await client.jsonVariation(flagKey, null);
7370
}
7471

7572
Alert.alert('LD Server Response', JSON.stringify(res));
@@ -121,10 +118,8 @@ const Body = () => {
121118
onValueChange={(itemValue, _) => setFlagType(itemValue)}>
122119
<Picker.Item label="Bool" value="bool" />
123120
<Picker.Item label="String" value="string" />
124-
<Picker.Item label="Int" value="int" />
125-
<Picker.Item label="Float" value="float" />
126-
<Picker.Item label="Array" value="array" />
127-
<Picker.Item label="Object" value="object" />
121+
<Picker.Item label="Number" value="number" />
122+
<Picker.Item label="JSON" value="json" />
128123
</Picker>
129124
<Text>Offline</Text>
130125
<Switch value={isOffline} onValueChange={setOffline} />
@@ -170,4 +165,26 @@ const App = () => {
170165
);
171166
}
172167

168+
MessageQueue.spy((msg) => {
169+
if (msg.module != 'LaunchdarklyReactNativeClient' && !msg.method.includes('LaunchdarklyReactNativeClient')) {
170+
return;
171+
}
172+
let logMsg = msg.type === 0 ? 'N->JS: ' : 'JS->N: ';
173+
logMsg += msg.method.replace('LaunchdarklyReactNativeClient.', '');
174+
175+
let params = [...msg.args];
176+
if (params.length >= 2) {
177+
let cbIdSucc = params[params.length - 1];
178+
let cbIdFail = params[params.length - 2];
179+
if (Number.isInteger(cbIdSucc) && Number.isInteger(cbIdFail) &&
180+
(cbIdSucc & 1) === 1 && (cbIdFail & 1) === 0 &&
181+
(cbIdSucc >>> 1 === cbIdFail >>> 1)) {
182+
params.splice(-2, 2, '<promise>');
183+
}
184+
}
185+
186+
logMsg += '(' + params.map(p => JSON.stringify(p)).join(', ') + ')';
187+
console.log(logMsg);
188+
});
189+
173190
export default App;

ManualTestApp/ios/Podfile.lock

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -72,14 +72,14 @@ PODS:
7272
- FlipperKit/FlipperKitNetworkPlugin
7373
- fmt (6.2.1)
7474
- glog (0.3.5)
75-
- LaunchDarkly (5.4.4):
76-
- LaunchDarkly/Core (= 5.4.4)
77-
- launchdarkly-react-native-client-sdk (5.1.1):
78-
- LaunchDarkly (= 5.4.4)
75+
- LaunchDarkly (6.0.0):
76+
- LaunchDarkly/Core (= 6.0.0)
77+
- launchdarkly-react-native-client-sdk (6.1.3):
78+
- LaunchDarkly (= 6.0.0)
7979
- React-Core
80-
- LaunchDarkly/Core (5.4.4):
81-
- LDSwiftEventSource (= 1.3.0)
82-
- LDSwiftEventSource (1.3.0)
80+
- LaunchDarkly/Core (6.0.0):
81+
- LDSwiftEventSource (= 1.3.1)
82+
- LDSwiftEventSource (1.3.1)
8383
- libevent (2.1.12)
8484
- OpenSSL-Universal (1.1.180)
8585
- RCT-Folly (2021.06.28.00-v2):
@@ -345,7 +345,7 @@ PODS:
345345
- React-jsi (= 0.67.2)
346346
- React-logger (= 0.67.2)
347347
- React-perflogger (= 0.67.2)
348-
- RNCPicker (2.2.1):
348+
- RNCPicker (2.4.1):
349349
- React-Core
350350
- Yoga (1.14.0)
351351
- YogaKit (1.18.1):
@@ -511,9 +511,9 @@ SPEC CHECKSUMS:
511511
FlipperKit: d8d346844eca5d9120c17d441a2f38596e8ed2b9
512512
fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9
513513
glog: 85ecdd10ee8d8ec362ef519a6a45ff9aa27b2e85
514-
LaunchDarkly: 99e279f0fb6f2c30e2b03ee84aa803eea56c9e7d
515-
launchdarkly-react-native-client-sdk: 7a8360469ea94b14fc04ee0fc48a301b2dcf9f81
516-
LDSwiftEventSource: bb05fa7955e1a5b0121c7d733f45d49fd0ef172f
514+
LaunchDarkly: 4f006a4f50a98221ed96f96564610e05662cdc99
515+
launchdarkly-react-native-client-sdk: 286fec4e737f40f322100be91b3fc803600e8165
516+
LDSwiftEventSource: 1ac1b0986a07c5fe4f2c94d87f1d41f4de6ae727
517517
libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913
518518
OpenSSL-Universal: 1aa4f6a6ee7256b83db99ec1ccdaa80d10f9af9b
519519
RCT-Folly: 803a9cfd78114b2ec0f140cfa6fa2a6bafb2d685
@@ -540,10 +540,10 @@ SPEC CHECKSUMS:
540540
React-RCTVibration: 99c7f67fba7a5ade46e98e870c6ff2444484f995
541541
React-runtimeexecutor: 2450b43df7ffe8e805a0b3dcb2abd4282f1f1836
542542
ReactCommon: d98c6c96b567f9b3a15f9fd4cc302c1eda8e3cf2
543-
RNCPicker: cb57c823d5ce8d2d0b5dfb45ad97b737260dc59e
543+
RNCPicker: abc646b53a3d28ccfa3232c927a0ca52e0cf024d
544544
Yoga: 9b6696970c3289e8dea34b3eda93f23e61fb8121
545545
YogaKit: f782866e155069a2cca2517aafea43200b01fd5a
546546

547547
PODFILE CHECKSUM: 9ed2f1671e477dd4514e541beaed8f012e67294d
548548

549-
COCOAPODS: 1.10.2
549+
COCOAPODS: 1.11.2

0 commit comments

Comments
 (0)