              return
  
          for attribute_name in self.user_attributes:
              value = getattr(user, attribute_name, None)
              if not value or not isinstance(value, string_types):
                  continue
              value_parts = re.split(r'\W+', value) + [value]
              for value_part in value_parts:
                  if SequenceMatcher(a=password.lower(), b=value_part.lower()).quick_ratio() >= self.max_similarity:
                      try:
 
</s> remove             return self.delimiter.join(six.text_type(self.base_field.prepare_value(v)) for v in value)
 </s> add             return self.delimiter.join(str(self.base_field.prepare_value(v)) for v in value) </s> remove                 if isinstance(items, six.string_types):
 </s> add                 if isinstance(items, str): </s> remove         if isinstance(value, six.string_types):
 </s> add         if isinstance(value, str): </s> remove         return six.text_type(value)
    elif isinstance(value, (decimal.Decimal, float) + six.integer_types):
 </s> add         return str(value)
    elif isinstance(value, (decimal.Decimal, float, int)): </s> remove         if isinstance(value, six.string_types):
 </s> add         if isinstance(value, str):
            if not value or not isinstance(value, str):
              return
  
          for attribute_name in self.user_attributes:
              value = getattr(user, attribute_name, None)
            if not value or not isinstance(value, str):
                  continue
              value_parts = re.split(r'\W+', value) + [value]
              for value_part in value_parts:
                  if SequenceMatcher(a=password.lower(), b=value_part.lower()).quick_ratio() >= self.max_similarity:
                      try:
keep keep keep keep replace keep keep keep keep keep
 Refs #23919 -- Removed six.<various>_types usage

Thanks Tim Graham and Simon Charette for the reviews. 
django/contrib/auth/password_validation.py