-
Notifications
You must be signed in to change notification settings - Fork 784
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
fix: event as list[AlertDTO] not included in the condition #2966
Conversation
@00041275 is attempting to deploy a commit to the KeepHQ Team on Vercel. A member of the Team first needs to authorize it. |
Thought we took care of it! Thank you. |
@00041275 may I ask you to create an issue for this PR too? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 1 Skipped Deployment
|
created #2974 |
🚂 Well done @00041275! Two PRs merged already! 🎉🥳 With your second PR, you're on a roll, and your contributions are already making a difference. 🌟 |
close #2974
📑 Description
in one of the conditions of the process_event function there is a flaw in processing event as a list. 2 months ago there was no such problem, but now when I upgraded the version of keep I found that zabbix provider started getting an error. while studying the issue (2 days) I finally understood what was the problem. The point is that in one of the conditions there is an attempt to convert dict into some formatted model, but the check condition checks list as well, without even trying to understand what is inside. The base_provider function requires implementing _format_alert, where event=dict. This means that you cannot pass list, or even list[alertDTO]. The change ensures that the _format_alert call is excluded if it is not dict.
base_provider
✅ Checks