tomchristie/django-rest-framework — pull request #1214 by diox (2013-11-05 16:25:38+00:00)
Title: Improve handling of 'empty' values for ChoiceField

The empty value defaults back to '' (for backwards-compatibility) but
is changed automatically to None for ModelSerializers if the `null`
property is set on the db field.

This should fix the backwards-compatibility issue introduced in #1074 while still fixing the original issue in that ticket.

I had type coercion coded but I can't find a benefit. If you can give me a testcase proving it's useful I can add it easily, following django's strategy for TypedChoiceFields.