def get_or_create_metric(name, slug):

    # This should be a NOOP for the non-database-backed backends
    if not should_create_models():
        return

    metric, created = Metric.objects.get_or_create(slug=slug, defaults={'name': name})
    return metric
Returns the metric with the given name and slug, creating
dataset/ETHPy150Open frankwiles/django-app-metrics/app_metrics/utils.py/get_or_create_metric