def set_log_level_for_all_loggers(level=logging.DEBUG):
    """
    Set a log level for all the loggers and handlers to the provided level.
    """
    root_logger = logging.getLogger()
    loggers = list(logging.Logger.manager.loggerDict.values())
    loggers += [root_logger]

    for logger in loggers:
        if not isinstance(logger, logging.Logger):
            continue

        set_log_level_for_all_handlers(logger=logger)

    Set a log level for all the loggers and handlers to the provided level.
    
st2client/st2client/utils/logging.py