ignore status_snr as it's deprecated

This commit is contained in:
luxifer 2022-11-18 22:25:10 +00:00
parent 40cd0127dc
commit d5f04c4999

View file

@ -30,7 +30,6 @@ class MetricInfo:
METRICS_INFO = { METRICS_INFO = {
"status_uptime": MetricInfo(unit="seconds", kind="counter"), "status_uptime": MetricInfo(unit="seconds", kind="counter"),
"status_snr": MetricInfo(),
"status_seconds_to_first_nonempty_slot": MetricInfo(), "status_seconds_to_first_nonempty_slot": MetricInfo(),
"status_pop_ping_drop_rate": MetricInfo(), "status_pop_ping_drop_rate": MetricInfo(),
"status_downlink_throughput_bps": MetricInfo(), "status_downlink_throughput_bps": MetricInfo(),
@ -162,6 +161,11 @@ def prometheus_export():
metrics = [] metrics = []
# snr is not supported by starlink any more but still returned by the grpc
# service for backwards compatibility
if "status_snr" in raw_data:
del raw_data["status_snr"]
metrics.append( metrics.append(
Metric( Metric(
name="starlink_status_state", name="starlink_status_state",