title: Django rest framework serializer.errors outputs ["This field is required."] with a multipart/form-data post request
body: <p>I've been looking at this for a while now, I'm sending out a post request with multipart/form-data, but get back the error ["This field is required."] for each field that I'm supposed to populate with the request.</p>
  
  <p>Here's the Serializer:</p>
  
  <pre><code>class InvoiceUploadSerializer(serializers.Serializer):
      serial=serializers.CharField(max_length=256, required=True)
      amount=serializers.CharField(max_length=256, required=True)
      debtor=serializers.CharField(max_length=256, required=True)
      dateout=serializers.CharField(max_length=256, required=True)
      expiration=serializers.CharField(max_length=256, required=True)
      invoicefile=serializers.FileField()
  
      class Meta:
          fields=('serial', 'amount', 'debtor', 'dateout', 'expiration', 'invoicefile',)
  </code></pre>
  
  <p>And the View:</p>
  
  <pre><code>class InvoiceViewSet(viewsets.ModelViewSet):
      queryset=Invoices.objects.all()
      serializer_class=InvoiceSerializer
      parser_classes=(MultiPartParser, FormParser)
  
      def get_permissions(self):
          if self.request.method in permissions.SAFE_METHODS:
              return (permissions.AllowAny(),)
  
          if self.request.method == 'POST':
              return (permissions.IsAuthenticated(),)
  
          return (permissions.IsAuthenticated(), IsAccountOwner(),)
  
      def create(self, request):
          serializer=InvoiceUploadSerializer(data=request.data)
          if serializer.is_valid():
              ... handle serializer
  
              return Response(serializer.validated_data, status=status.HTTP_201_CREATED)
          else:
              emessage=serializer.errors
              return Response({
                  'status': 'Bad request',
                  'message': emessage,
              }, status=status.HTTP_400_BAD_REQUEST
  </code></pre>
  
  <p>Here is a picture showing the browser console with the outgoing request:
  <a href="https://i.stack.imgur.com/1d46L.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/1d46L.png" alt="enter image description here"></a></p>
  
  <p>And lastly the error message from the browser console:
  <a href="https://i.stack.imgur.com/wdcKp.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/wdcKp.png" alt="enter image description here"></a></p>
  
  <p>I don't understand why it tells me all fields are missing, the header is set correctly and it looks fine to me. </p>
  
  <p>Switched up the view-code and urls still the same error, New with the same problem:</p>
  
  <pre><code>class InvoiceUploadView(APIView):
      parser_classes=(MultiPartParser, FormParser)
      def get_permissions(self):
          return (permissions.AllowAny(),)
  
      def post(self, request):
          serializer=InvoiceUploadSerializer(data=request.POST)
          if serializer.is_valid():
              return Response(serializer.validated_data, status=status.HTTP_201_CREATED)
          else:
              emessage=serializer.errors
              return Response({
                  'status': 'Bad request',
                  'message': emessage,
              }, status=status.HTTP_400_BAD_REQUEST)
  </code></pre>