          self.queryset = kwargs.pop('queryset', None)
          self.many = kwargs.pop('many', False)
          super(RelatedField, self).__init__(**kwargs)
  
      def get_queryset(self):
          queryset = self.queryset
          if isinstance(queryset, QuerySet):
 
</s> remove def get_default_queryset(serializer_class, field_name):
    manager = getattr(serializer_class.opts.model, field_name)
    if hasattr(manager, 'related'):
        # Forward relationships
        return manager.related.model._default_manager.all()
    # Reverse relationships
    return manager.field.rel.to._default_manager.all()


 </s> add  </s> remove         if isinstance(self.queryset, QuerySet):
 </s> add         if isinstance(queryset, QuerySet): </s> remove     def get_url(self, obj, view_name, request, format):
        """
        Given an object, return the URL that hyperlinks to the object.

        May raise a `NoReverseMatch` if the `view_name` and `lookup_field`
        attributes are not configured to correctly match the URL conf.
        """
        # Unsaved objects will not yet have a valid URL.
        if obj.pk is None:
            return None

        lookup_value = getattr(obj, self.lookup_field)
        kwargs = {self.lookup_url_kwarg: lookup_value}
        return reverse(view_name, kwargs=kwargs, request=request, format=format)

 </s> add  </s> remove         msg = self.error_messages['invalid'] % humanized_format
        raise ValidationError(msg)
 </s> add         self.fail('invalid', format=humanized_format) </s> remove         msg = self.error_messages['invalid'] % humanized_format
        raise ValidationError(msg)
 </s> add         self.fail('invalid', format=humanized_format)
        assert self.queryset is not None or kwargs.get('read_only', False), (
            'Relational field must provide a `queryset` argument, '
            'or set read_only=`True`.'
        )
          self.queryset = kwargs.pop('queryset', None)
          self.many = kwargs.pop('many', False)
        assert self.queryset is not None or kwargs.get('read_only', False), (
            'Relational field must provide a `queryset` argument, '
            'or set read_only=`True`.'
        )
          super(RelatedField, self).__init__(**kwargs)
  
      def get_queryset(self):
          queryset = self.queryset
          if isinstance(queryset, QuerySet):
keep add keep keep keep keep keep
 Clean up relational fields queryset usage 
rest_framework/relations.py