Cleaning up name before appending unit on name#543
Cleaning up name before appending unit on name#543brian-brazil merged 1 commit intoprometheus:masterfrom
Conversation
| self.assertRaises(ValueError, Info, 'foo', 'help', unit="x") | ||
| self.assertRaises(ValueError, Enum, 'foo', 'help', unit="x") | ||
|
|
||
| def test_name_cleanup_before_unit_append(self): |
There was a problem hiding this comment.
Can we also add a test that this is exposed correctly somewhere?
There was a problem hiding this comment.
Added on tests/test_asgi.py and tests/test_wsgi.py
There was a problem hiding this comment.
Those are additional handlers, text_exposition would be the best place to put it.
695e1bd to
644d4cf
Compare
Signed-off-by: Amim Knabben <amim.knabben@gmail.com>
|
Thanks! |
|
Hello, is this change intended? I was looking at it with the following: |
Unit append in the name were being removed when _total exists. This moves the clean up before appending the unit.
Refs #542
@brian-brazil Should this "repeated" unit raise an ValueError exception instead since this suffix is already append when dumping on WSGI.