Python django.conf.settings 模块,SILENCED_SYSTEM_CHECKS 实例源码

我们从Python开源项目中,提取了以下1个代码示例,用于说明如何使用django.conf.settings.SILENCED_SYSTEM_CHECKS

项目:python-dockerflow    作者:mozilla-services    | 项目源码 | 文件源码
def heartbeat_check_detail(check):
    errors = check(app_configs=None)
    errors = list(filter(lambda e: e.id not in settings.SILENCED_SYSTEM_CHECKS, errors))
    level = max([0] + [e.level for e in errors])

    return {
        'status': level_to_text(level),
        'level': level,
        'messages': {e.id: e.msg for e in errors},
    }