Releases: launchdarkly/python-server-sdk
Releases · launchdarkly/python-server-sdk
6.4.0
[6.4.0] - 2018-08-29
Added:
- The new
LDClientmethodvariation_detailallows you to evaluate a feature flag (using the same parameters as you would forvariation) and receive more information about how the value was calculated. This information is returned in anEvaluationDetailobject, which contains both the result value and a "reason" object which will tell you, for instance, if the user was individually targeted for the flag or was matched by one of the flag's rules, or if the flag returned the default value due to an error.
Fixed:
- When evaluating a prerequisite feature flag, the analytics event for the evaluation did not include the result value if the prerequisite flag was off.
6.3.0
[6.3.0] - 2018-08-27
Added:
- The new
LDClientmethodall_flags_state()should be used instead ofall_flags()if you are passing flag data to the front end for use with the JavaScript SDK. It preserves some flag metadata that the front end requires in order to send analytics events correctly. Versions 2.5.0 and above of the JavaScript SDK are able to use this metadata, but the output ofall_flags_state()will still work with older versions. - The
all_flags_state()method also allows you to select only client-side-enabled flags to pass to the front end, by using the optionclient_side_only=True.
Deprecated:
LDClient.all_flags()
6.2.0
[6.2.0] - 2018-08-03
Changed:
- In streaming mode, each connection failure or unsuccessful reconnection attempt logs a message at
ERRORlevel. Previously, this message included the amount of time before the next retry; since that interval is different for each attempt, that meant theERROR-level messages were all unique, which could cause problems for monitors. This has been changed so theERROR-level message is always the same, and is followed by anINFO-level message about the time delay. (Note that in order to suppress the default message, the LaunchDarkly client modifies the logger used by thebackoffpackage; if you are usingbackofffor some other purpose and do want to see the default message, setlogging.getLogger('backoff').propagatetoTrue.) (#88)
6.1.1
[6.1.1] - 2018-06-19
Fixed:
- Removed an unused dependency on the
CacheControlpackage.
6.1.0
[6.1.0] - 2018-06-18
Changed:
- The client now uses
urllib3for HTTP requests, rather than therequestspackage. This change was made becauserequestshas a dependency on an LGPL-licensed package, and some of our customers cannot use LGPL code. The networking behavior of the client should be unchanged. - The client now treats most HTTP 4xx errors as unrecoverable: that is, after receiving such an error, it will not make any more HTTP requests for the lifetime of the client instance, in effect taking the client offline. This is because such errors indicate either a configuration problem (invalid SDK key) or a bug in the client, which will not resolve without a restart or an upgrade. This does not apply if the error is 400, 408, 429, or any 5xx error.
- During initialization, if the client receives any of the unrecoverable errors described above,
ldclient.get()will return immediately; previously it would continue waiting until a timeout. Theis_initialized()method will return false in this case.
6.0.4
[6.0.4] - 2018-06-12
Fixed:
- Fixed a bug introduced in v6.0.3 that caused the user cache for analytics events to never be cleared, also causing an
AttributeErrorto appear in the log.
6.0.3
[6.0.3] - 2018-05-30
Removed:
- Removed a dependency on the
pylrupackage, because it uses a GPL license.
Fixed:
- Fixed a bug that, in Python 3.x, could cause a timer thread to keep running after the client has been shut down. This bug also caused the message "TypeError: Event object is not callable" to be logged.
- Fixed the
Configinitializer to create a new instance ofInMemoryFeatureStoreif you omit thefeature_storeargument. Previously, allConfiginstances that were created with default parameters would share the same feature store instance. - Clarified HTTP proxy setup instructions in the readme.
6.0.2
[6.0.2] - 2018-05-25
Fixed:
- Fixed a bug that caused an error message to be logged (
KeyError: 'default') when evaluating a prerequisite flag (and that also prevented an analytics event from being sent for that flag). - When running in uWSGI, the client will no longer log an error message if the
enableThreadsoption is absent, as long as thethreadsoption has been set to a number greater than 1. (#84)
6.0.0
[6.0.0] - 2018-05-10
Changed:
- To reduce the network bandwidth used for analytics events, feature request events are now sent as counters rather than individual events, and user details are now sent only at intervals rather than in each event. These behaviors can be modified through the LaunchDarkly UI and with the new configuration option
inline_users_in_events. For more details, see Analytics Data Stream Reference. - The analytics event processor now flushes events at a configurable interval defaulting to 5 seconds, like the other SDKs (previously it flushed if no events had been posted for 5 seconds, or if events exceeded a configurable number). This interval is set by the new
Configpropertyflush_interval.
Removed:
- Python 2.6 is no longer supported.
- Removed the
Configpropertyevents_upload_max_batch_size, which is no longer relevant in the new event flushing logic (see above).