Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(181)

Unified Diff: ppapi/PRESUBMIT.py

Issue 379923010: [PPAPI] Make the NaCl SDK presubmit check a warning instead of an error. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/PRESUBMIT.py
diff --git a/ppapi/PRESUBMIT.py b/ppapi/PRESUBMIT.py
index c8d61784888e4daa77d5d62a96a974cb81ac9653..ddbd31475c66bd391dc5e46fc9a716c81eadb4e8 100644
--- a/ppapi/PRESUBMIT.py
+++ b/ppapi/PRESUBMIT.py
@@ -8,16 +8,20 @@ import sys
import subprocess
-def RunCmdAndCheck(cmd, err_string, output_api, cwd=None):
+def RunCmdAndCheck(cmd, err_string, output_api, cwd=None, warning=False):
results = []
p = subprocess.Popen(cmd, cwd=cwd,
stdout=subprocess.PIPE,
stderr=subprocess.PIPE)
(p_stdout, p_stderr) = p.communicate()
if p.returncode:
- results.append(
- output_api.PresubmitError(err_string,
- long_text=p_stderr))
+ if warning:
+ results.append(output_api.PresubmitPromptWarning(
+ '%s\n\n%s' % (err_string, p_stderr)))
+ else:
+ results.append(
+ output_api.PresubmitError(err_string,
+ long_text=p_stderr))
return results
@@ -141,8 +145,11 @@ def CheckUpdatedNaClSDK(input_api, output_api):
'verify_ppapi.py')
cmd = [sys.executable, verify_ppapi_py] + nacl_sdk_files
return RunCmdAndCheck(cmd,
- 'PPAPI Interface modified without updating NaCl SDK.',
- output_api)
+ 'PPAPI Interface modified without updating NaCl SDK.\n'
+ '(note that some dev interfaces should not be added '
+ 'the NaCl SDK; when in doubt, ask a ppapi OWNER.)',
+ output_api,
+ warning=True)
# Verify that changes to ppapi/thunk/interfaces_* files have a corresponding
# change to tools/metrics/histograms/histograms.xml for UMA tracking.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698