  
      In the case of REST Framework, the filter is used to add Bootstrap-specific
      classes to the forms.
      """
      html = six.text_type(value)
      match = class_re.search(html)
      if match:
          m = re.search(r'^%s$|^%s\s|\s%s\s|\s%s$' % (css_class, css_class,
                                                      css_class, css_class),
                        match.group(1))
 
</s> remove @python_2_unicode_compatible
class PKOnlyObject(object):
 </s> add class PKOnlyObject: </s> remove class ForcedAuthentication(object):
 </s> add class ForcedAuthentication: </s> remove         request = super(ViewSetMixin, self).initialize_request(request, *args, **kwargs)
 </s> add         request = super().initialize_request(request, *args, **kwargs) </s> remove             content_type = "{0}; charset={1}".format(
 </s> add             content_type = "{}; charset={}".format( </s> remove from __future__ import unicode_literals

 </s> add 
    html = str(value)
  
      In the case of REST Framework, the filter is used to add Bootstrap-specific
      classes to the forms.
      """
    html = str(value)
      match = class_re.search(html)
      if match:
          m = re.search(r'^%s$|^%s\s|\s%s\s|\s%s$' % (css_class, css_class,
                                                      css_class, css_class),
                        match.group(1))
keep keep keep keep replace keep keep keep keep keep
 Dropped Python 2 compatibility. (#6615)

Thanks to Jon Dufresne (@jdufresne) for review.

Co-authored-by: Asif Saif Uddin <auvipy@gmail.com>
Co-authored-by: Rizwan Mansuri <Rizwan@webbyfox.com> 
rest_framework/templatetags/rest_framework.py