code: def deserialize_data(self, data, data_type):
          
          if data is None:
              return data
  
          try:
              if not data_type:
                  return data
              if data_type in self.basic_types.values():
                  return self.deserialize_basic(data, data_type)
              if data_type in self.deserialize_type:
                  if isinstance(data, self.deserialize_expected_types.get(data_type, tuple())):
                      return data
  
                  is_a_text_parsing_type = lambda x: x not in ["object", "[]", r"{}"]
                  if isinstance(data, ET.Element) and is_a_text_parsing_type(data_type) and not data.text:
                      return None
                  data_val = self.deserialize_type[data_type](data)
                  return data_val
  
              iter_type = data_type[0] + data_type[-1]
              if iter_type in self.deserialize_type:
                  return self.deserialize_type[iter_type](data, data_type[1:-1])
  
              obj_type = self.dependencies[data_type]
              if issubclass(obj_type, Enum):
                  if isinstance(data, ET.Element):
                      data = data.text
                  return self.deserialize_enum(data, obj_type)
  
          except (ValueError, TypeError, AttributeError) as err:
              msg = "Unable to deserialize response data."
              msg += " Data: {}, {}".format(data, data_type)
              raise_with_traceback(DeserializationError, msg, err)
          else:
              return self._deserialize(obj_type, data)
docs: Process data for deserialization according to data type.
  
          :param str data: The response string to be deserialized.
          :param str data_type: The type to deserialize to.
          :raises: DeserializationError if deserialization fails.
          :return: Deserialized object.