depot_toools: Make subcommand Python 3 compatible.

Bug: 984182
Change-Id: I5d1b5626eb799975539560ca1508af92df326d47
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/1721916
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
This commit is contained in:
Edward Lemur
2019-08-03 01:26:06 +00:00
committed by Commit Bot
parent 59bb8cce84
commit 921f6a1751

View File

@@ -160,7 +160,7 @@ class CommandDispatcher(object):
commands = self.enumerate_commands()
docs = sorted(
(cmd_name, self._create_command_summary(cmd_name, handler))
for cmd_name, handler in commands.iteritems())
for cmd_name, handler in commands.items())
# Skip commands without a docstring.
docs = [i for i in docs if i[1]]
# Then calculate maximum length for alignment: