Index: tools/presubmit.py |
diff --git a/tools/presubmit.py b/tools/presubmit.py |
index fda7ba96e5957a5b91c98f120af4c1708ed8c9a4..7af6e3d0d80e3a85c7606af692c8b1c249e78922 100755 |
--- a/tools/presubmit.py |
+++ b/tools/presubmit.py |
@@ -211,7 +211,12 @@ class CppLintProcessor(SourceFileProcessor): |
if exists(local_cpplint): |
command = ['python', local_cpplint, '--filter', filt] + join(files) |
- process = subprocess.Popen(command, stderr=subprocess.PIPE) |
+ try: |
+ process = subprocess.Popen(command, stderr=subprocess.PIPE) |
+ except: |
+ print('Error running cpplint.py. Please make sure you have depot_tools' + |
+ ' in your $PATH. Lint check skipped.') |
+ return True |
LINT_ERROR_PATTERN = re.compile(r'^(.+)[:(]\d+[:)]') |
while True: |
out_line = process.stderr.readline() |