Check_temperature werk for 2.3p7 leads to crashing checks which still use unique_name

Hi @ll,

it seems that because of this issue: Rittal temperature check regression check_temperature has been updated in the last three days and it is now not possible to use the unique_name variable in the check_temperature function any more.
This fix also been pushed into the 2.3 branch for p7 but we are using the unique_name in some of our current check plugins, and the error leads to hundreds of crashing checks from devices where temperatures are present.
Isn´t that in incompatible change in a major version that should at least be documented or announced anywhere ?

@andreas-doehler @martin.hirschvogel

Hi @aeckstein,

You’re right, I missed that. We will revert the change and improve the situation in a different way.

Regards
Timi

For some context:
Strictly speaking, the code you are using is not part of the API, so we do not promise a stable interface here. However, we sympathize with your situation, and in this case we can go for a different solution that will not break your code.
But beware: Maybe in the future we will (have to) make incompatible changes to that code.

It’s unfortunate: We currently can’t promise stability here, on the other hand we do believe it is desirable to have a consistent plugin landscape. Using these functions is one of the best ways to achieve that – with the severe downside you are currently experiencing.

I think this shows a need for yet another API that Checkmk should consider commiting to: Some check plugins that do offer a stable interface to tap into. For some types of checks (temperature, fans, diskspace and CPU utilization, for instance) it would be nice to have canonical plugins that can be easily used by creating appropriate section plugins (which was not possible pre “Check API” version 1). That would increase consistency a lot, and avoid this problem.
Alas – there’s so much to do…

1 Like

Thank you both for the quick response and the clarification !

I really have no problem adapting the code for 2.4 to adapt to necessary api changes and use stable interfaces, but not between 2.3p6 and p7 :wink:

yes :slight_smile:

And to clarify - this was in a daily build, not in an official release, no one was harmed :slight_smile:

In that case: Kudos for spotting it in time :smiley: .

1 Like

@aeckstein FYI: this is now the way to go in master: Improve typing on check_temperature · Checkmk/checkmk@d4ab1ae · GitHub

for 2.3, I am still in discussion if we backport it