def get_or_else(data, key, default_value = None):
   """
   Tries to get a value from data with key. Returns default_value in case of key
   not found.
   """
   if not data:
      return default_value
   try:
      return data[key]
   except:
      return default_value