Skip to content

Fix ValueError('Incorrect label names')#159

Merged
sven-rosenzweig merged 1 commit intostable/2024.1-m3from
fix_metrics
Jan 20, 2026
Merged

Fix ValueError('Incorrect label names')#159
sven-rosenzweig merged 1 commit intostable/2024.1-m3from
fix_metrics

Conversation

@sven-rosenzweig
Copy link
Contributor

When request errors occur (e.g. ConnectTimeout),
the path label was not added to the Prometheus metric, causing a ValueError.

@sven-rosenzweig sven-rosenzweig requested a review from mutax January 20, 2026 12:58
@sven-rosenzweig sven-rosenzweig requested review from a team as code owners January 20, 2026 12:58
@github-actions
Copy link

github-actions bot commented Jan 20, 2026

Name                                                                      Stmts   Miss  Cover
---------------------------------------------------------------------------------------------
networking_nsxv3/api/rpc.py                                                 250    121    52%
networking_nsxv3/common/config.py                                            16      0   100%
networking_nsxv3/common/constants.py                                         23      0   100%
networking_nsxv3/common/locking.py                                           35     11    69%
networking_nsxv3/common/synchronization.py                                  378     73    81%
networking_nsxv3/db/db.py                                                   119     19    84%
networking_nsxv3/extensions/nsxtoperations.py                               110     29    74%
networking_nsxv3/extensions/nsxtpolicy.py                                    84      7    92%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/agent.py                   174     60    66%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/cli.py                     302    199    34%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/client_nsx.py              211     51    76%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/constants_nsx.py             6      0   100%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/extensions/firewall.py      27      0   100%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/provider.py                171     10    94%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/provider_nsx_policy.py     778    113    85%
networking_nsxv3/plugins/ml2/drivers/nsxv3/agent/realization.py             238     59    75%
networking_nsxv3/plugins/ml2/drivers/nsxv3/driver.py                        143     74    48%
networking_nsxv3/prometheus/exporter.py                                      21      5    76%
networking_nsxv3/services/logapi/drivers/nsxv3/driver.py                     41      1    98%
networking_nsxv3/services/qos/drivers/nsxv3/qos.py                           34      4    88%
networking_nsxv3/services/trunk/drivers/nsxv3/trunk.py                       71      3    96%
---------------------------------------------------------------------------------------------
TOTAL                                                                      3232    839    74%

When request errors occur (e.g. ConnectTimeout),
the `path` label was not added to the Prometheus metric, causing a ValueError.
@sven-rosenzweig sven-rosenzweig merged commit feee59b into stable/2024.1-m3 Jan 20, 2026
4 checks passed
@sven-rosenzweig sven-rosenzweig deleted the fix_metrics branch January 20, 2026 14:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants