@@ -22,6 +22,15 @@ Release History
2222 + Migration: If you still need to treat an ``Event `` as a ``dict ``, you can get a deepcopy of the original ``dict ``
2323 using the new property on ``BaseAPIJSONObject ``, ``response_object ``.
2424
25+ - The logging format strings in ``LoggingNetwork `` have changed in a way that
26+ will break logging for any applications that have overridden any of these
27+ strings. They now use keyword format placeholders instead of positional
28+ placeholders. All custom format strings will now have to use the same keyword
29+ format placeholders. Though this is a breaking change, the good news is that
30+ using keyword format placeholders means that any future changes will be
31+ automatically backwards-compatibile (as long as there aren't any changes to
32+ change/remove any of the keywords).
33+
2534**Features **
2635
2736- Added more flexibility to the object translation system:
@@ -35,8 +44,36 @@ Release History
3544 referenced by the ``BoxSession ``, instead of directly using the global
3645 default ``Translator ``.
3746
47+ - When the ``auto_session_renewal `` is ``True `` when calling any of the request
48+ methods on ``BoxSession ``, if there is no access token, ``BoxSession `` will
49+ renew the token _before_ making the request. This saves an API call.
50+ - Various enhancements to the ``JWTAuth `` baseclass:
51+
52+ - The ``authenticate_app_user() `` method is renamed to
53+ ``authenticate_user() ``, to reflect that it may now be used to authenticate
54+ managed users as well. See the method docstring for details.
55+ ``authenticate_app_user() `` is now an alias of ``authenticate_user() ``, in
56+ order to not introduce an unnecessary backwards-incompatibility.
57+ - The ``user `` argument to ``authenticate_user() `` may now be either a user
58+ ID string or a ``User `` instance. Before it had to be a ``User `` instance.
59+ - The constructor now accepts an optional ``user `` keyword argument, which
60+ may be a user ID string or a ``User `` instance. When this is passed,
61+ ``authenticate_user() `` and can be called without passing a value for the
62+ ``user `` argument. More importantly, this means that ``refresh() `` can be
63+ called immediately after construction, with no need for a manual call to
64+ ``authenticate_user() ``. Combined with the aforementioned improvement to
65+ the ``auto_session_renewal `` functionality of ``BoxSession ``, this means
66+ that authentication for ``JWTAuth `` objects can be done completely
67+ automatically, at the time of first API call.
68+ - Document that the ``enterprise_id `` argument to ``JWTAuth `` is allowed to
69+ be ``None ``.
70+ - ``authenticate_instance() `` now accepts an ``enterprise `` argument, which
71+ can be used to set and authenticate as the enterprise service account user,
72+ if ``None `` was passed for ``enterprise_id `` at construction time.
73+
3874- Added an ``Event `` class.
39- - Moved `metadata ` method to `Item ` so it's now available for `Folder ` as well as `File `.
75+ - Moved ``metadata() `` method to ``Item `` so it's now available for ``Folder ``
76+ as well as ``File ``.
4077
4178**Other **
4279
@@ -47,7 +84,20 @@ Release History
4784 ``BaseObject `` is the parent of all objects that are a part of the REST API. Another subclass of
4885 ``BaseAPIJSONObject ``, ``APIJSONObject ``, was created to represent pseudo-smart objects such as ``Event `` that are not
4986 directly accessible through an API endpoint.
87+ - Added ``network_response_constructor `` as an optional property on the
88+ ``Network `` interface. Implementations are encouraged to override this
89+ property, and use it to construct ``NetworkResponse `` instances. That way,
90+ subclass implementations can easily extend the functionality of the
91+ ``NetworkResponse ``, by re-overriding this property. This property is defined
92+ and used in the ``DefaultNetwork `` implementation.
93+ - Move response logging to a new ``LoggingNetworkResponse `` class (which is
94+ made possible by the aforementioned ``network_response_constructor ``
95+ property). Now the SDK decides whether to log the response body, based on
96+ whether the caller reads or streams the content.
97+ - Add more information to the request/response logs from ``LoggingNetwork ``.
98+ - Add logging for request exceptions in ``LoggingNetwork ``.
5099- Fixed an exception that was being raised from ``ExtendableEnumMeta.__dir__() ``.
100+ - CPython 3.6 support.
51101
521021.5.3 (2016-05-26)
53103++++++++++++++++++
0 commit comments