              else:
                  rel_obj = None
          if ct_id is not None:
              ct = self.get_content_type(id=ct_id, using=instance._state.db)
              with suppress(ObjectDoesNotExist):
                  rel_obj = ct.get_object_for_this_type(pk=pk_val)
          self.set_cached_value(instance, rel_obj)
          return rel_obj
  
      def __set__(self, instance, value):
 
</s> remove             with suppress(TemplateDoesNotExist):
 </s> add             try: </s> remove             with suppress(ImportError):
 </s> add             try:
            try:
              else:
                  rel_obj = None
          if ct_id is not None:
              ct = self.get_content_type(id=ct_id, using=instance._state.db)
            try:
                  rel_obj = ct.get_object_for_this_type(pk=pk_val)
          self.set_cached_value(instance, rel_obj)
          return rel_obj
  
      def __set__(self, instance, value):
keep keep keep keep replace keep keep keep keep keep
 Reverted "Fixed #27818 -- Replaced try/except/pass with contextlib.suppress()."

This reverts commit 550cb3a365dee4edfdd1563224d5304de2a57fda
because try/except performs better. 
django/contrib/contenttypes/fields.py