              self.validators.append(validators.MaxLengthValidator(self.max_length))
  
      def deconstruct(self):
          name, path, args, kwargs = super().deconstruct()
          del kwargs['editable']
          return name, path, args, kwargs
  
      def get_internal_type(self):
          return "BinaryField"
  
 
</s> remove         kwargs['editable'] = False
 </s> add         kwargs.setdefault('editable', False) </s> remove to filter a queryset on a ``BinaryField`` value. It is also not possible to
include a ``BinaryField`` in a :class:`~django.forms.ModelForm`.
 </s> add to filter a queryset on a ``BinaryField`` value.

By default, ``BinaryField`` sets :attr:`~Field.editable` to ``False``, in which
case it can't be included in a :class:`~django.forms.ModelForm`.

.. versionchanged:: 2.1

    Older versions don't allow setting ``editable`` to ``True``.
        if self.editable:
            kwargs['editable'] = True
        else:
            del kwargs['editable']
              self.validators.append(validators.MaxLengthValidator(self.max_length))
  
      def deconstruct(self):
          name, path, args, kwargs = super().deconstruct()
        if self.editable:
            kwargs['editable'] = True
        else:
            del kwargs['editable']
          return name, path, args, kwargs
  
      def get_internal_type(self):
          return "BinaryField"
  
keep keep keep keep replace keep keep keep keep keep
 Fixed #28937 -- Allowed BinaryField to be editable=True. 
django/db/models/fields/__init__.py