Use tryint() for stats value

In some cases the value is [not set], in this case
the conversion to integer does not work.

Closes-Bug: #1970431
Change-Id: I74df7d8bc9f5cbe0709a6471cf7639caea0b58e8
This commit is contained in:
Harald Jensås
2022-04-26 15:46:56 +02:00
parent 3b0c035b90
commit bab0c92103

View File

@@ -31,7 +31,7 @@ def get_service_stats(service):
if not line:
continue
stat, val = line.split('=')
stats[stat] = int(val)
stats[stat] = tryint(val)
return stats