Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I am using the latest version of Prometheus_ When accessing the 8888 port on the client, an error was reported. What should I do #10

Open
busy-tester opened this issue Nov 19, 2023 · 0 comments

Comments

@busy-tester
Copy link

Start local_ Exporter
python3 locust_exporter.py 8888 127.0.0.1:8089
I am using the latest version of Prometheus_ When accessing the 8888 port on the client, an error was reported. What should I do
liufujia@zou python_protobuf % python3 locust_exporter.py 8888 127.0.0.1:8089 Connecting to locust on: 127.0.0.1:8089 Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/wsgiref/handlers.py", line 137, in run self.result = application(self.environ, self.start_response) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/prometheus_client/exposition.py", line 128, in prometheus_app status, headers, output = _bake_output(registry, accept_header, accept_encoding_header, params, disable_compression) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/prometheus_client/exposition.py", line 104, in _bake_output output = encoder(registry) ^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/prometheus_client/exposition.py", line 228, in generate_latest output.append(sample_line(s)) ^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/prometheus_client/exposition.py", line 185, in sample_line ['{}="{}"'.format( File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/prometheus_client/exposition.py", line 186, in <listcomp> k, v.replace('\\', r'\\').replace('\n', r'\n').replace('"', r'\"')) ^^^^^^^^^ AttributeError: ("'NoneType' object has no attribute 'replace'", Metric(locust_requests_avg_content_length, Locust requests avg_content_length, gauge, , [Sample(name='locust_requests_avg_content_length', labels={'path': '/lb/v1/dashboard/project', 'method': 'GET'}, value=83.0, timestamp=None, exemplar=None), Sample(name='locust_requests_avg_content_length', labels={'path': 'Aggregated', 'method': None}, value=83.0, timestamp=None, exemplar=None)]))
image

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

No branches or pull requests

1 participant