-
Notifications
You must be signed in to change notification settings - Fork 474
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
17219 FIX gcp_status: Fix KeyError: 'global'
This change affects users which have configured the rule 'Google Cloud Platform (GCP) Status'. Previously, Checkmk did not handle incidents correctly, which had set `global` as an associated location. This was the corresponding traceback: ``` File "/omd/sites/mon_home/lib/python3/cmk/plugins/gcp/agent_based/gcp_status.py", line 72, in parse data.setdefault(constants.RegionMap[location.id_], []).append(incident) KeyError: 'global' ``` With this werk, the crash is fixed. SUP-21870 Change-Id: I56b787d1526d228027d4dc4f9ad5ac069e3aa85e
- Loading branch information
1 parent
95e26dd
commit bc6b506
Showing
3 changed files
with
109 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
[//]: # (werk v2) | ||
# gcp_status: Fix KeyError: 'global' | ||
|
||
key | value | ||
---------- | --- | ||
date | 2025-01-02T13:02:00+00:00 | ||
version | 2.4.0b1 | ||
class | fix | ||
edition | cre | ||
component | checks | ||
level | 1 | ||
compatible | yes | ||
|
||
This change affects users which have configured the rule 'Google Cloud Platform (GCP) Status'. | ||
Previously, Checkmk did not handle incidents correctly, which had set `global` as an associated location. | ||
This was the corresponding traceback: | ||
``` | ||
File "/omd/sites/mon_home/lib/python3/cmk/plugins/gcp/agent_based/gcp_status.py", line 72, in parse | ||
data.setdefault(constants.RegionMap[location.id_], []).append(incident) | ||
KeyError: 'global' | ||
``` | ||
With this werk, the crash is fixed. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters