Skip to content

Commit

Permalink
fix: linter
Browse files Browse the repository at this point in the history
  • Loading branch information
pgimalac committed Feb 18, 2025
1 parent ceb5e23 commit 29d64b5
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ def _parse_payload(fd):
"""
from prometheus_client.metrics_core import Metric
from prometheus_client.parser import _parse_sample, _replace_help_escaping

name = ''
documentation = ''
typ = 'untyped'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,7 @@ def parse_metrics(self):
def parse_metric_families(self):
from prometheus_client.parser import text_fd_to_metric_families as parse_prometheus
from prometheus_client.openmetrics.parser import text_fd_to_metric_families as parse_openmetrics

media_type = self._content_type.split(';')[0]
# Setting `use_latest_spec` forces the use of the OpenMetrics format, otherwise
# the format will be chosen based on the media type specified in the response's content-header.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ def decumulate_histogram_buckets(sample_data):
Decumulate buckets in a given histogram metric and adds the lower_bound label (le being upper_bound)
"""
from prometheus_client.samples import Sample

# TODO: investigate performance optimizations
new_sample_data = []
bucket_values_by_context_upper_bound = {}
Expand Down

0 comments on commit 29d64b5

Please sign in to comment.