Werk #15709: Fix "Transform spool files" update issue

Component Core & setup
Title Fix "Transform spool files" update issue
Date Jul 4, 2023
Level Trivial Change
Class Bug Fix
Compatibility Compatible - no manual interaction needed
Checkmk versions & editions
2.3.0b1 Checkmk Raw (CRE), Checkmk Enterprise (CEE), Checkmk Cloud (CCE), Checkmk MSP (CME)
2.2.0p5 Checkmk Raw (CRE), Checkmk Enterprise (CEE), Checkmk Cloud (CCE), Checkmk MSP (CME)

Empty files in notification spool directories did break the update procedure in previous 2.2 version, which prevented the update procedure from ensuring a consistent configuration and runtime data.

The related error looked like this:

-| 18/20 Transform spool files...
-| + "Transform spool files" failed
-| Traceback (most recent call last):
-| File "/omd/sites/semitan/lib/python3/cmk/update_config/main.py", line 223, in _call_
-| action(self._logger, self.update_state.setdefault(action.name))
-| File "/omd/sites/semitan/lib/python3/cmk/update_config/cee/plugins/actions/notifications.py", line 31, in _call_
-| data["context"] = transform_flexible_and_plain_context(data["context"])
-| ~~~~^^^^^^^^^^^
-| KeyError: 'context'

To the list of all Werks