def get_level(request):
 storage = getattr(request, '_messages', default_storage(request))
 return storage.level

def get_level ( request ) : storage = getattr ( request , '_messages' , default_storage ( request ) ) return storage . level
returns the minimum level of messages to be recorded .