Skip to content

Commit

Permalink
Fixed flake8 errors for kafka/tools/assigner/actions/demote.py
Browse files Browse the repository at this point in the history
The flake8 errors were part of the reason why Travis build was failing for PR #91 for linkedin/kafka-tools. The other factor was tox running into an upstream python bug [1] for which PR #94 has been raised. I confirmed that after these 2 factors were eliminated, the build passes [2].

[1] https://bugs.python.org/issue10496
[2] akashvacher@2228e65
  • Loading branch information
akashvacher committed Jul 9, 2018
1 parent fe7e188 commit 0057090
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions kafka/tools/assigner/actions/demote.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,8 @@ def __init__(self, args, cluster):
def _add_args(cls, parser):
parser.add_argument(
'-b', '--brokers', type=int, help='List of broker ids to demote', required=True, nargs='*')
parser.add_argument('-t', '--topics', required=False, nargs='*', help=\
'Optional list of topics to use. If not specified, leadership of all topics lead by the brokers to ' \
'demote will be changed.')
parser.add_argument('-t', '--topics', required=False, nargs='*',
help='Optional list of topics to use. If not specified, leadership of all topics lead by the brokers to demote will be changed.')

def process_cluster(self):
brokers_to_demote = set(self.args.brokers)
Expand Down

0 comments on commit 0057090

Please sign in to comment.