mirror of
https://github.com/git-for-windows/git.git
synced 2025-12-14 18:43:41 -06:00
git-p4: seperate multiple statements onto seperate lines
PEP8 discourages the use of compound statements where there are multiple statements on a single line in the "Other Recommendations" section: https://www.python.org/dev/peps/pep-0008/#other-recommendations Signed-off-by: Joel Holdsworth <jholdsworth@nvidia.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
4768af2088
commit
e8f8b3b2a3
@ -1191,7 +1191,8 @@ def p4ChangesForPaths(depotPaths, changeRange, requestedBlockSize):
|
|||||||
else:
|
else:
|
||||||
block_size = max(2, block_size // 2)
|
block_size = max(2, block_size // 2)
|
||||||
|
|
||||||
if verbose: print("block size error, retrying with block size {0}".format(block_size))
|
if verbose:
|
||||||
|
print("block size error, retrying with block size {0}".format(block_size))
|
||||||
continue
|
continue
|
||||||
except P4Exception as e:
|
except P4Exception as e:
|
||||||
die('Error retrieving changes description ({0})'.format(e.p4ExitCode))
|
die('Error retrieving changes description ({0})'.format(e.p4ExitCode))
|
||||||
@ -1818,7 +1819,9 @@ class P4Submit(Command, P4UserMap):
|
|||||||
(changelist, newUser))
|
(changelist, newUser))
|
||||||
|
|
||||||
c = changes[0]
|
c = changes[0]
|
||||||
if c['User'] == newUser: return # nothing to do
|
if c['User'] == newUser:
|
||||||
|
# Nothing to do
|
||||||
|
return
|
||||||
c['User'] = newUser
|
c['User'] = newUser
|
||||||
# p4 does not understand format version 3 and above
|
# p4 does not understand format version 3 and above
|
||||||
input = marshal.dumps(c, 2)
|
input = marshal.dumps(c, 2)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user