From 82b1dbc1b21a482ffe8330ed924b4265f09d83b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=9Clgen=20Sar=C4=B1kavak?= Date: Sun, 8 Jun 2025 16:27:21 +0300 Subject: [PATCH] Update ruff to the latest (0.11.13) version --- django_prometheus/db/metrics.py | 4 ++-- django_prometheus/exports.py | 2 +- django_prometheus/middleware.py | 2 +- tox.ini | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/django_prometheus/db/metrics.py b/django_prometheus/db/metrics.py index 01403213..4eb3dab9 100644 --- a/django_prometheus/db/metrics.py +++ b/django_prometheus/db/metrics.py @@ -18,7 +18,7 @@ execute_total = Counter( "django_db_execute_total", - ("Counter of executed statements by database and by vendor, including" " bulk executions."), + ("Counter of executed statements by database and by vendor, including bulk executions."), ["alias", "vendor"], namespace=NAMESPACE, ) @@ -26,7 +26,7 @@ execute_many_total = Counter( "django_db_execute_many_total", - ("Counter of executed statements in bulk operations by database and" " by vendor."), + ("Counter of executed statements in bulk operations by database and by vendor."), ["alias", "vendor"], namespace=NAMESPACE, ) diff --git a/django_prometheus/exports.py b/django_prometheus/exports.py index 94c04156..79f3b3f7 100644 --- a/django_prometheus/exports.py +++ b/django_prometheus/exports.py @@ -93,7 +93,7 @@ def SetupPrometheusEndpointOnPortRange(port_range, addr=""): thread.start() logger.info("Exporting Prometheus /metrics/ on port %s" % port) return port # Stop trying ports at this point - logger.warning("Cannot export Prometheus /metrics/ - " "no available ports in supplied range") + logger.warning("Cannot export Prometheus /metrics/ - no available ports in supplied range") return None diff --git a/django_prometheus/middleware.py b/django_prometheus/middleware.py index 86573abc..8c6f88d6 100644 --- a/django_prometheus/middleware.py +++ b/django_prometheus/middleware.py @@ -36,7 +36,7 @@ def register(self): self.requests_latency_before = self.register_metric( Histogram, "django_http_requests_latency_including_middlewares_seconds", - ("Histogram of requests processing time (including middleware " "processing time)."), + ("Histogram of requests processing time (including middleware processing time)."), buckets=PROMETHEUS_LATENCY_BUCKETS, namespace=NAMESPACE, ) diff --git a/tox.ini b/tox.ini index 68418018..4a450c87 100644 --- a/tox.ini +++ b/tox.ini @@ -34,7 +34,7 @@ commands = [testenv:py39-lint] deps = - ruff==0.8.2 + ruff==0.11.13 commands = ruff format --check django_prometheus/ ruff check django_prometheus/