          assert 'allow_null' not in kwargs, '`allow_null` is not a valid option.'
          kwargs['allow_null'] = True
          super().__init__(**kwargs)
  
      def to_internal_value(self, data):
          try:
              if data in self.TRUE_VALUES:
                  return True
              elif data in self.FALSE_VALUES:
                  return False
              elif data in self.NULL_VALUES:
                  return None
          except TypeError:  # Input is an unhashable type
              pass
          self.fail('invalid', input=data)
  
      def to_representation(self, value):
          if value in self.NULL_VALUES:
              return None
          if value in self.TRUE_VALUES:
              return True
          elif value in self.FALSE_VALUES:
              return False
          return bool(value)
  
  
  # String types...
  
  class CharField(Field):
 
</s> remove         super().__init__(**kwargs)
 </s> add  </s> remove class NullBooleanField(Field):
    default_error_messages = {
        'invalid': _('Must be a valid boolean.')
    }
 </s> add class NullBooleanField(BooleanField): </s> remove     if model_field.null and not isinstance(model_field, models.NullBooleanField):
 </s> add     if model_field.null: </s> remove     TRUE_VALUES = {
        't', 'T',
        'y', 'Y', 'yes', 'YES',
        'true', 'True', 'TRUE',
        'on', 'On', 'ON',
        '1', 1,
        True
    }
    FALSE_VALUES = {
        'f', 'F',
        'n', 'N', 'no', 'NO',
        'false', 'False', 'FALSE',
        'off', 'Off', 'OFF',
        '0', 0, 0.0,
        False
    }
    NULL_VALUES = {'null', 'Null', 'NULL', '', None}
 </s> add 
        super().__init__(**kwargs)
          assert 'allow_null' not in kwargs, '`allow_null` is not a valid option.'
          kwargs['allow_null'] = True
          super().__init__(**kwargs)
  
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
        super().__init__(**kwargs)
  
  
  # String types...
  
  class CharField(Field):
keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace replace keep keep keep keep keep
 Merge NullBooleanField with BooleanField(allow_null=True) (#7122)

* Make `NullBooleanField` subclass `BooleanField`

This removes a lot of the redundancy that was in place becuase we
were not doing this. This maintains the `None` initial value that
was previously present, as well as disallowing `allow_null` to be
passed in.

* Remove special case for mapping `NullBooleanField`

In newer versions of Django, the `NullBooleanField` is handled the
same way as a `BooleanField(null=True)`. Given that we also support
that combination, and that our own `NullBooleanField` behaves in the
same manner, it makes sense to remove the special casing that exists
for it.

* Add test for BooleanField(null=True, choices)

* Remove special case for NullBooleanField

* Adjust mapping tests for NullBooleanField

* Fixed linting error

* Raise deprecation warning when NullBooleanField is used

* Fix linting issue in imports 
rest_framework/fields.py