Saggi Mizrahi has posted comments on this change.
Change subject: utils: Correct and faster list2cmdline ......................................................................
Patch Set 7:
(1 comment)
http://gerrit.ovirt.org/#/c/27548/7/lib/vdsm/utils.py File lib/vdsm/utils.py:
Line 731: Line 732: if not printable: Line 733: printable = command Line 734: Line 735: execCmdLogger.debug("%s (cwd %s)", _list2cmdline(printable), cwd)
Sure we can, but using this all over the code is little ugly.
Seems a bit too clever. Assumes a lot about the inner workings of the formatting command. Also, I'd much rather people avoid using LazyString.
We could just push a LogAdapter that process %(cmd)s with _list2cmdline.
But I don't think we need either. We rarely need to do this kind of stuff anyway. Line 736: Line 737: p = CPopen(command, close_fds=True, cwd=cwd, env=env, Line 738: deathSignal=deathSignal, childUmask=childUmask) Line 739: if not sync: