Change in vdsm[master]: pep8ize vdsm/vdsm entry point
zhshzhou at linux.vnet.ibm.com
zhshzhou at linux.vnet.ibm.com
Tue Sep 18 01:11:52 UTC 2012
Zhou Zheng Sheng has posted comments on this change.
Change subject: pep8ize vdsm/vdsm entry point
......................................................................
Patch Set 1: Verified
(1 inline comment)
Run through autobuild.sh.
pydiff reports same changes, they are splitting big import into small ones, acceptable.
$ pydiff vdsmo vdsm
11 difference(s)
first file: vdsmo
second file: vdsm
((11, ('sys', None)), ('11 + -', None))
((11, ('getopt', None)), ('11 + -', None))
((11, ('signal', None)), ('11 + -', None))
((12, 'getpass'), (12, 'sys'))
((12, ('pwd', None)), ('12 + -', None))
((12, ('grp', None)), ('12 + -', None))
(('12 +', None), (13, Import([('getopt', None)])))
(('12 +', None), (14, Import([('signal', None)])))
(('12 +', None), (15, Import([('getpass', None)])))
(('12 +', None), (16, Import([('pwd', None)])))
(('12 +', None), (17, Import([('grp', None)])))
You may notice I update pydiff to get more meaningful report, to get the latest version, please see https://github.com/edwardbadboy/pydiff
....................................................
File vdsm/vdsm
Line 116: )
Line 117: group = grp.getgrnam(constants.VDSM_GROUP)
Line 118: assert ((constants.VDSM_USER in group.gr_mem
Line 119: or pwd.getpwnam(constants.VDSM_USER).pw_gid == group.gr_gid),
Line 120: "VDSM failed to start: vdsm user is not in KVM group")
Could it be better
assert ((constants.VDSM_USER in group.gr_mem
or pwd.getpwnam(constants.VDSM_USER).pw_gid == group.gr_gid),
"VDSM failed to start: vdsm user is not in KVM group")
I mean the message is the same level as the "(constants...)",
Line 121:
Line 122: if __name__ == '__main__':
Line 123: __assertVdsmUser()
Line 124: os.setpgrp()
--
To view, visit http://gerrit.ovirt.org/8026
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ia8c20b5dad7bf502e2862db14d6062ddc239ca3c
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Ryan Harper <ryanh at us.ibm.com>
Gerrit-Reviewer: Zhou Zheng Sheng <zhshzhou at linux.vnet.ibm.com>
More information about the vdsm-patches
mailing list