I had to add extraneous parens to a while condition today to avoid pep8 complaints:
while not found and not something and \
(time_left is None or time_left > 0):
(one, two, three, four) = self.gimme(timeout=time_left)
My solution:
while (not found and not something and
(time_left is None or time_left > 0)):
(one, two, three, four) = self.gimme(timeout=time_left)
If I changed the 2nd line indent, it complained of over-indent or missing indent, for every indent from even with the W in while, to 8 to the right of it.
I'm bothered that adding extraneous parens to satisfy pep8, for little readability improvement, goes against general principles.
Any ideas? Have I missed a better solution?
I prefer to break the long lines after conditional statements to increase readability. e.g.:
I think that is very readable and at least satisfies my pep8 codestyle check.