From Dan Kenigsberg <danken(a)redhat.com>:
Dan Kenigsberg has submitted this change and it was merged.
Change subject: cmdutils: Fix message format
......................................................................
cmdutils: Fix message format
In commit fb57a5a34adf (errors: Use new errors.Base class) I made a typo
on cmdutils.Error msg format string. Raising this error will show now
this error instead of the original error:
Traceback (most recent call last):
File "/home/nsoffer/src/vdsm/tests/cmdutils_test.py", line 119, in
test_format
str(cmdutils.Error(["cmd"], 1, "out\n", "err\n"))
File "/home/nsoffer/src/vdsm/lib/vdsm/common/errors.py", line 35, in __str__
return self.msg.format(self=self)
KeyError: 'sef'
This patch fixes the typo and add the missing test for this class.
Change-Id: Ic2348aa107cb09d3db6c9a8875a984b62b76c3ff
Signed-off-by: Nir Soffer <nsoffer(a)redhat.com>
---
M lib/vdsm/cmdutils.py
M tests/cmdutils_test.py
2 files changed, 8 insertions(+), 1 deletion(-)
Approvals:
Nir Soffer: Verified
Jenkins CI: Passed CI tests
Dan Kenigsberg: Looks good to me, approved
--
To view, visit
https://gerrit.ovirt.org/74625
To unsubscribe, visit
https://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ic2348aa107cb09d3db6c9a8875a984b62b76c3ff
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Adam Litke <alitke(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation(a)ovirt.org>