Skip to content

Commit 92c9290

Browse files
committed
Version 2.2.5
1 parent 8387cb5 commit 92c9290

File tree

4 files changed

+12
-4
lines changed

4 files changed

+12
-4
lines changed

docs/api-guide/fields.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,12 +197,16 @@ If you want to override this behavior, you'll need to declare the `DateTimeField
197197
class Meta:
198198
model = Comment
199199

200+
Note that by default, datetime representations are deteremined by the renderer in use, although this can be explicitly overridden as detailed below.
201+
202+
In the case of JSON this means the default datetime representation uses the [ECMA 262 date time string specification][ecma262]. This is a subset of ISO 8601 which uses millisecond precision, and includes the 'Z' suffix for the UTC timezone, for example: `2013-01-29T12:34:56.123Z`.
203+
200204
**Signature:** `DateTimeField(format=None, input_formats=None)`
201205

202206
* `format` - A string representing the output format. If not specified, this defaults to `None`, which indicates that python `datetime` objects should be returned by `to_native`. In this case the datetime encoding will be determined by the renderer.
203207
* `input_formats` - A list of strings representing the input formats which may be used to parse the date. If not specified, the `DATETIME_INPUT_FORMATS` setting will be used, which defaults to `['iso-8601']`.
204208

205-
DateTime format strings may either be [python strftime formats][strftime] which explicitly specifiy the format, or the special string `'iso-8601'`, which indicates that [ISO 8601][iso8601] style datetimes should be used. (eg `'2013-01-29T12:34:56.000000'`)
209+
DateTime format strings may either be [python strftime formats][strftime] which explicitly specifiy the format, or the special string `'iso-8601'`, which indicates that [ISO 8601][iso8601] style datetimes should be used. (eg `'2013-01-29T12:34:56.000000Z'`)
206210

207211
## DateField
208212

@@ -318,5 +322,6 @@ As an example, let's create a field that can be used represent the class name of
318322

319323
[cite]: https://docs.djangoproject.com/en/dev/ref/forms/api/#django.forms.Form.cleaned_data
320324
[FILE_UPLOAD_HANDLERS]: https://docs.djangoproject.com/en/dev/ref/settings/#std:setting-FILE_UPLOAD_HANDLERS
325+
[ecma262]: http://ecma-international.org/ecma-262/5.1/#sec-15.9.1.15
321326
[strftime]: http://docs.python.org/2/library/datetime.html#strftime-and-strptime-behavior
322327
[iso8601]: http://www.w3.org/TR/NOTE-datetime

docs/api-guide/serializers.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ Passing `allow_add_remove=True` ensures that any update operations will complete
256256

257257
#### How identity is determined when performing bulk updates
258258

259-
Performing a bulk update is slightly more complicated than performing a bulk creation, because the serializer needs a way of determining how the items in the incoming data should be matched against the existing object instances.
259+
Performing a bulk update is slightly more complicated than performing a bulk creation, because the serializer needs a way to determine how the items in the incoming data should be matched against the existing object instances.
260260

261261
By default the serializer class will use the `id` key on the incoming data to determine the canonical identity of an object. If you need to change this behavior you should override the `get_identity` method on the `Serializer` class. For example:
262262

docs/topics/release-notes.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,11 @@ You can determine your currently installed version using `pip freeze`:
4040

4141
## 2.2.x series
4242

43-
### Master
43+
### 2.2.5
4444

45+
**Date**: 26th March 2013
46+
47+
* Serializer support for bulk create and bulk update operations.
4548
* Regression fix: Date and time fields return date/time objects by default. Fixes regressions caused by 2.2.2. See [#743][743] for more details.
4649
* Bugfix: Fix 500 error is OAuth not attempted with OAuthAuthentication class installed.
4750
* `Serializer.save()` now supports arbitrary keyword args which are passed through to the object `.save()` method. Mixins use `force_insert` and `force_update` where appropriate, resulting in one less database query.

rest_framework/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
__version__ = '2.2.4'
1+
__version__ = '2.2.5'
22

33
VERSION = __version__ # synonym
44

0 commit comments

Comments
 (0)