Univention Bugzilla – Bug 53926
univention-maintenance-mode-update-progress: increase robustness
Last modified: 2021-10-18 18:25:14 CEST
echo > /var/lib/univention-updater/univention-updater.status Traceback (most recent call last): File "/usr/share/univention-maintenance-mode-update-progress", line 137, in <module> main() File "/usr/share/univention-maintenance-mode-update-progress", line 132, in main compute() File "/usr/share/univention-maintenance-mode-update-progress", line 110, in compute percentage = read_progress() File "/usr/share/univention-maintenance-mode-update-progress", line 47, in read_progress if updater_status.status == 'DONE': AttributeError: 'UpdaterStatus' object has no attribute 'status' echo > /var/lib/univention-updater/univention-updater.status.details echo -en 'current_version=5.0-0\nnext_version=5.0-0\ntarget_version=5.0-1\ntype=foo\nstatus=foo\nerrorsource=foo' > /var/lib/univention-updater/univention-updater.status Traceback (most recent call last): File "/usr/share/univention-maintenance-mode-update-progress", line 137, in <module> main() File "/usr/share/univention-maintenance-mode-update-progress", line 132, in main compute() File "/usr/share/univention-maintenance-mode-update-progress", line 115, in compute percentage = add_updater_context(percentage) File "/usr/share/univention-maintenance-mode-update-progress", line 100, in add_updater_context return (finished_updates * 100.0 + percentage) / float(len(updater_status.overall_updates)) ZeroDivisionError: float division by zero