Commit 104ca4d0 authored by Josip Sokcevic's avatar Josip Sokcevic Committed by LUCI CQ

Use input_api.sys instead of import sys

Follow up on https://crrev.com/c/2929386

R=dpranke@google.com

Change-Id: Id977cfae561ecfb231372348387b084e098e6747
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2947981
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Dirk Pranke <dpranke@google.com>
Auto-Submit: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: 's avatarDirk Pranke <dpranke@google.com>
parent b9236628
......@@ -944,7 +944,6 @@ def GetPylint(input_api,
input_api.logging.debug(' with extra PYTHONPATH: %r', extra_paths_list)
def GetPylintCmd(flist, extra, parallel):
import sys
# Windows needs help running python files so we explicitly specify
# the interpreter to use. It also has limitations on the size of
# the command-line, so we pass arguments via a pipe.
......@@ -976,7 +975,7 @@ def GetPylint(input_api,
description += ' on %d cores' % input_api.cpu_count
kwargs['stdin'] = '\n'.join(args + flist)
if sys.version_info.major != 2:
if input_api.sys.version_info.major != 2:
kwargs['stdin'] = kwargs['stdin'].encode('utf-8')
return input_api.Command(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment