Skip to content

fix: handle dict type trigger_string in alert deduplication for Cline #1163

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

Merged
merged 2 commits into from
Mar 3, 2025

Conversation

lukehinds
Copy link
Contributor

The alert deduplication logic was failing when trigger_string was a dictionary, causing an AttributeError when trying to call split() on it. Updated the code to:

  • Check trigger_string type before processing
  • Handle dictionary case by creating a consistent JSON string from relevant fields
  • Maintain existing string handling for backwards compatibility
  • Add fallback for other types by converting to string

This ensures alerts are properly deduplicated regardless of trigger_string format.

Fixes: #1162

yrobla
yrobla previously approved these changes Feb 28, 2025
lukehinds and others added 2 commits February 28, 2025 09:35
The alert deduplication logic was failing when trigger_string was a dictionary,
causing an AttributeError when trying to call split() on it. Updated the code to:

- Check trigger_string type before processing
- Handle dictionary case by creating a consistent JSON string from relevant fields
- Maintain existing string handling for backwards compatibility
- Add fallback for other types by converting to string

This ensures alerts are properly deduplicated regardless of trigger_string format.

Fixes: #1162
@aponcedeleonch aponcedeleonch merged commit 6f41eae into main Mar 3, 2025
11 checks passed
@aponcedeleonch aponcedeleonch deleted the bug-1162 branch March 3, 2025 08:21
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.

Fix Cline dict handling
3 participants