def contains_profiler(func_tuple):
 has_profiler = False
 for value in func_tuple:
  if isinstance(value, six.string_types):
   has_profiler |= (INVALID_PROFILER_FUNC in value)
 return has_profiler

def contains_profiler ( func_tuple ) : has_profiler = False for value in func_tuple : if isinstance ( value , six . string_types ) : has_profiler |= ( INVALID_PROFILER_FUNC in value ) return has_profiler
helper function that checks to see if the tuple contains the invalid_profile_func in any string value of the tuple .