def _is_valid_legacy_metric_name(name: str) -> bool:
    """Returns true if the provided metric name conforms to the legacy validation scheme."""
    return METRIC_NAME_RE.match(name) is not None
Returns true if the provided metric name conforms to the legacy validation scheme.
prometheus_client/validation.py