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

1.6.0 TypeError, 1.5.3 works #147

Closed
EvertonSA opened this issue Sep 20, 2023 · 5 comments · Fixed by #150
Closed

1.6.0 TypeError, 1.5.3 works #147

EvertonSA opened this issue Sep 20, 2023 · 5 comments · Fixed by #150

Comments

@EvertonSA
Copy link
Contributor

Describe the bug
A clear and concise description of what the bug is.
After upgrading from 1.5.3 to 1.6.0, we get the following error:

│ ❱ 201 │ │ related_pods = [pod["metric"]["pod"] for pod in related_pods_result]
TypeError: string indices must be integers, not 'str'

After checking v1.5.3 again, it works as expected.

To Reproduce
Steps to reproduce the behavior:
Unfortunately, I'm not sure how to reproduce other than running python .\krr.py simple on a working prometheus setup.

Expected behavior
I would expect to have same behavior as 1.5.3

Screenshots
If applicable, add screenshots to help explain your problem.
image

@EvertonSA
Copy link
Contributor Author

i'm willing to provide further data, or test release candidate fixes if needed

@LeaveMyYard
Copy link
Contributor

Hey, @EvertonSA!

Your error is a bit odd - custom_query returns something unexpected
Can you add

raise Exception(related_pods_result)

before

related_pods = [pod["metric"]["pod"] for pod in related_pods_result]

in robusta_krr/core/integrations/prometheus/metrics_service/prometheus_metrics_service.py, run it and then show me the resulted exception, to help me to understand what's going on? Thank you in advance

@LeaveMyYard
Copy link
Contributor

Also this might be somehow related to #127

@LeaveMyYard
Copy link
Contributor

@EvertonSA Can you try #150 ?

@EvertonSA
Copy link
Contributor Author

I confirm #150 150 works !

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 a pull request may close this issue.

2 participants