title: Django serializers: validate function not called
body: <p>I am trying override <code>validate()</code> function to be called by <code>serializers.is_valid()</code>, but its not getting called.</p>
  
  <p><strong>serializer.py</strong></p>
  
  <pre><code>class LoginSerializer(serializers.Serializer):
      email = serializers.EmailField(max_length=255,required=True)
      password = serializers.CharField(max_length=128,required=True)
  
  
      def validate(self,data):
         '''
         Check for invalid email.
         &amp; blank email and password. 
         '''
  
         print 'hey i am in login'
  
         if data['email'] is '':
             raise serializers.ValidationError("Email cannot be empty.")
         if data['password'] is '':
            raise serializers.ValidationError("Password cannot be empty.")
         try:
            validate_email(data['email'])
         except ValidationError:
            raise serializers.ValidationError("The email is not a valid email address.")
         return data
  </code></pre>
  
  <p><strong>views.py</strong></p>
  
  <pre><code>class LoginAPI(APIView):
      permission_classes = (permissions.AllowAny,)
      serializer = LoginSerializer
  
      def post(self, request):
         data = self.serializer(data=request.data)
         if data.is_valid():
            #do something
         else:
             return Response(data.errors,status=status.HTTP_400_BAD_REQUEST)
  </code></pre>
  
  <p>while i call <code>is_valid()</code>, the print statement inside <code>validate()</code> function is not getting executed.
  what am i doing wrong?</p>