[ZBX-23551] Widget Top Hosts applies decimal numbers on Integer values Created: 2023 Oct 16  Updated: 2024 Apr 10  Resolved: 2023 Dec 07

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Frontend (F)
Affects Version/s: 6.4.7
Fix Version/s: None

Type: Problem report Priority: Major
Reporter: Karel Bělunek Assignee: Zabbix Development Team
Resolution: Won't fix Votes: 2
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

RHEL9, Zabbix 6.4.7


Attachments: PNG File image-2023-10-16-11-46-33-874.png    
Team: Team A
Sprint: Sprint 105 (Oct 2023)

 Description   

Problem description

Widget Top hosts in 6.4 added possibility to define decimal numbers in numeric items, like it was before possible in widget "Item value". Problem is that "Item value" applies this setting only on float values, "Top hosts" applies it on both float and integer.

In the case of newly created Dashboards it can be easily avoided usinm "0" value, but problem is when dashboards are part of Zabbix 6.0 now upgraded to 6.4. Now every dashboard (hundreds) needs manual change to set value to 0. 

Probably caused by ZBXNEXT:
https://support.zabbix.com/browse/ZBXNEXT-8165

Docs for "Top hosts":

Decimal places Specify how many decimal places will be displayed with the value.
This setting applies only to numeric data.

 

Dosc for "Item value":

Decimal places Select how many decimal places will be displayed with the value. This value will affect only float items.

 

Steps to reproduce:

  1. Create "Top hosts" widget and column with some integer Item value, e.g. No of CPU cores. Left "Decimal places" as default "2"

Result:
See screenshot...

Expected:
Integer Items displayed without decimals at all regardles of widget settings.



 Comments   
Comment by Dmitrijs Fofanovs [ 2023 Dec 07 ]

WON'T fix as was discussed during https://support.zabbix.com/browse/ZBXNEXT-8165 decimal places should stay for all types of items but will be processed for numeric item values only.
Some of the points why:

  • different hosts can have different item types with same key and name.
  • aggregation enabled with avg almost 90% time converts integer to float values.
Generated at Sat Dec 13 22:03:42 EET 2025 using Jira 10.3.13#10030013-sha1:56dd970ae30ebfeda3a697d25be1f6388b68a422.