You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
See title. This is due to an isinstance check in converters.get_choices that changes the iterable if the choices are an OrderedDict. Django REST Framework 3.15.0 changed from OrderedDicts to regular dicts, so this check no longer converts the iterable, meaning the loop now tries to iterate the dict by keys, but unpack it to two variables, which is not possible.
I should be able to use serializer mutations with choice fields in DRF 3.15.0.
Changing the isinstance check to isinstance(choices, dict) should solve the issue without any breaking anything for older versions of DRF, as OrderedDicts are subclasses of dicts.