-
Type:
Incident report
-
Resolution: Unresolved
-
Priority:
Trivial
-
None
-
Affects Version/s: 7.0.22
-
Component/s: Server (S)
-
None
-
Environment:zabbix server 7.0.22
In Zabbix 7.0.22, when a master item discards a value via preprocessing (MATCHES_REGEX + DISCARD_VALUE). Then dependent item is still processed and receives an internal value of type none. The dependent item’s REGEX "^(.*)$" preprocessing then fails with:
Preprocessing failed for: Failed: cannot perform regular expression "^(.*)$" match for value of type "none": cannot convert value to string
Instead, when the master’s value is discarded, the dependent item should not be processed at all (or at least should not get a none value that causes a regex error). This behavior appears only in 7.0.22; in 7.0.0–7.0.21 the same configuration works without errors.
Steps to reproduce:
use template:
zabbix_export: version: '7.0' template_groups: - uuid: c9ad55ebe7c343bd9d0e617fd1823ff1 name: 'ED Templates' templates: - uuid: ae5c82b3bcd64f6393f7007ee8cfc4c6 template: test.dep.issue name: test.dep.issue groups: - name: 'ED Templates' items: - uuid: 0faab50f68f9441fb2fbef00ebe7bf42 name: test.dep type: DEPENDENT key: test.dep delay: '0' preprocessing: - type: REGEX parameters: - '^(.*)$' - \1 master_item: key: test.master - uuid: 76f339a8ba6149c7b362dffdc52e7080 name: test.master type: SCRIPT key: test.master delay: 10s params: 'return 0;' preprocessing: - type: MATCHES_REGEX parameters: - '[1]' error_handler: DISCARD_VALUE
Result:

Preprocessing failed for: 1. Failed: cannot perform regular expression "^(.*)$" match for value of type "none": cannot convert value to string
Expected:

any fail