mirror of
https://github.com/YunoHost/tartiflette.git
synced 2024-09-03 20:06:08 +02:00
Fix history script
This commit is contained in:
parent
ca5852c85f
commit
590d6b9524
1 changed files with 4 additions and 4 deletions
|
@ -95,17 +95,17 @@ def make_count_summary():
|
||||||
infos = j.get(app, {})
|
infos = j.get(app, {})
|
||||||
|
|
||||||
if not infos or infos.get("state") not in ["working", "official"]:
|
if not infos or infos.get("state") not in ["working", "official"]:
|
||||||
level = -1
|
level = 0
|
||||||
else:
|
else:
|
||||||
level = infos.get("level", -1)
|
level = infos.get("level", 0)
|
||||||
try:
|
try:
|
||||||
level = int(level)
|
level = int(level)
|
||||||
except:
|
except:
|
||||||
level = -1
|
level = 0
|
||||||
|
|
||||||
history_per_app[app].append({
|
history_per_app[app].append({
|
||||||
"date": d_label,
|
"date": d_label,
|
||||||
"level": infos.get("level", -1)
|
"level": level
|
||||||
})
|
})
|
||||||
|
|
||||||
json.dump(history, open('count_history.json', 'w'))
|
json.dump(history, open('count_history.json', 'w'))
|
||||||
|
|
Loading…
Reference in a new issue