MCPcopy Index your code
hub / github.com/prometheus/client_python / Collector

Class Collector

tests/test_exposition.py:458–465  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

456
457
458class Collector:
459 def __init__(self, metric_family, *values):
460 self.metric_family = metric_family
461 self.values = values
462
463 def collect(self):
464 self.metric_family.add_metric([], *self.values)
465 return [self.metric_family]
466
467
468def _expect_metric_exception(registry, expected_error):

Callers 3

Calls

no outgoing calls

Tested by 3