              'many': to_many
          }
  
          if model_field:
              kwargs['required'] = not(model_field.null or model_field.blank)
              if model_field.help_text is not None:
                  kwargs['help_text'] = model_field.help_text
              if model_field.verbose_name is not None:
                  kwargs['label'] = model_field.verbose_name
  
 
</s> remove         if model_field.null or model_field.blank:
 </s> add         if model_field.null or model_field.blank and model_field.editable: </s> remove             kwargs['required'] = not(model_field.null or model_field.blank)
 </s> add             kwargs['required'] = not(model_field.null or model_field.blank) and model_field.editable
            kwargs['required'] = not(model_field.null or model_field.blank) and model_field.editable
              'many': to_many
          }
  
          if model_field:
            kwargs['required'] = not(model_field.null or model_field.blank) and model_field.editable
              if model_field.help_text is not None:
                  kwargs['help_text'] = model_field.help_text
              if model_field.verbose_name is not None:
                  kwargs['label'] = model_field.verbose_name
  
keep keep keep keep replace keep keep keep keep keep
 Frameworks throws AssertionError saying you cannot set required=True and read_only=True on editable=False model fields.  We should not make the field required if editable=False. 
rest_framework/serializers.py