Closed pmg103 closed 4 years ago
serialization_spec = [ {'product_versions': [ 'id', {'product': [ 'name', ]}, ]}, {'product_versions': [ 'id', ]}, # ...
Will result in this error:
'product_versions' lookup was already seen with a different queryset. You may need to adjust the ordering of your lookups.
being thrown inside this line in GenericAPIView .get_object():
GenericAPIView .get_object()
obj = get_object_or_404(queryset, **filter_kwargs)
https://github.com/encode/django-rest-framework/blob/0407a0df8a16fdac94bbd08d49143a74a88001cd/rest_framework/generics.py#L96
which will give a 404 and silently consume the exception :/
I think this may be resolved now because specs are merged/normalised
Will result in this error:
'product_versions' lookup was already seen with a different queryset. You may need to adjust the ordering of your lookups.
being thrown inside this line in
GenericAPIView .get_object()
:https://github.com/encode/django-rest-framework/blob/0407a0df8a16fdac94bbd08d49143a74a88001cd/rest_framework/generics.py#L96
which will give a 404 and silently consume the exception :/