The repository has not been cloned yet. Run the following command first
to clone the repo, check out the target commit, and install dependencies:
bash
bash /setup_files/setup.sh
The code will then be available at /testbed.
You are working on the repository prometheus/client_python (instance: prometheus__client_python-1121).
The code is located in /testbed.
##1118 Implement deletion of Gauge metrics based on partially specified labels
In many cases, the labels of a Gauge are fixed and known, but sometimes it’s hard to keep track of all labels, for example with an HTTP request collector per endpoint.
It would be very useful to have a method to delete metrics by matching a subset of labels. For example, deleting all metrics with status_code="200" regardless of other labels.
I ran into this issue myself when scraping disk data from multiple instances. On reset I wanted to remove only a specific instance's metrics, but ended up removing all.