Central method where we control whether warnings should be displayed

def should_display_warnings_for(to_type):
    """ Central method where we control whether warnings should be displayed """
    if not hasattr(to_type, '__module__'):
        return True
    elif to_type.__module__ in {'builtins'} or to_type.__module__.startswith('parsyfiles') \
            or to_type.__name__ in {'DataFrame'}:
        return False
    elif issubclass(to_type, int) or issubclass(to_type, str) \
            or issubclass(to_type, float) or issubclass(to_type, bool):
        return False
    else:
        return True