Werk #14418: Changes in rendering functions used in legacy check API
|Component||Checks & agents|
|Title||Changes in rendering functions used in legacy check API|
|Date||Jun 16, 2022|
|Checkmk Editon||Checkmk Raw (CRE)|
|Compatibility||Incompatible - Manual interaction might be required|
This werk might be incompatible only for users with custom check plugins in the legacy check API. The following rendering functions in the legacy check API have been changed. In case you are negatively affected by these changes, we strongly recommend to migrate to the new API (see this blog post for help and further references).
- get_age_human_readable: Changes in rendering format only, no API changes.
- get_bytes_human_readable: SI and IEC prefixes are now used consistently, see also werk #14417. Furthermore, the value for the base argument must now be either 1,000 or 1,024, any other value results in a ValueError. Finally, the argument precision is now ignored. Instead, the number of decimal places is set automatically.
- get_nic_speed_human_readable: Changes in rendering format only, no API changes.
- get_percent_human_readable: The argument scientific_notation is now ignored. Hence, values are not rendered in scientific notation any more. Furthermore, percentages are always rendered with two decimal places, except for very small values.
- get_number_with_precision: No unit prefixes are added any more to the rendered value. Instead, the value is displayed as is with the specified number of decimal places. Hence, the argument base is now ignored. Furthermore, the arguments drop_zeroes and zero_non_decimal are also ignored.