Some time ago we introduced some improvements in
ZBX-4284. But looks like this logic is lost now, because I can reproduce the original case.
Or the improved logic was very specific, so it does not cover many/most real cases.
I faced with the issue a few times for short period recently.
Evaluate please that.