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

Unified Diff: PRESUBMIT.py

Issue 11496010: PRESUBMIT #include check: don't add a warning if we're committing. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 | PRESUBMIT_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: PRESUBMIT.py
diff --git a/PRESUBMIT.py b/PRESUBMIT.py
index ff620c1852ae742c9995ae8005d7e6ab2a02d326..9acfcb281054a834ff6b9229622417bbf865a886 100644
--- a/PRESUBMIT.py
+++ b/PRESUBMIT.py
@@ -619,8 +619,13 @@ def _CheckIncludeOrder(input_api, output_api):
results = []
if warnings:
- results.append(output_api.PresubmitPromptWarning(_INCLUDE_ORDER_WARNING,
- warnings))
+ if not input_api.is_committing:
+ results.append(output_api.PresubmitPromptWarning(_INCLUDE_ORDER_WARNING,
+ warnings))
+ else:
+ # We don't warn on commit, to avoid stopping commits going through CQ.
+ results.append(output_api.PresubmitNotifyResult(_INCLUDE_ORDER_WARNING,
+ warnings))
return results
« no previous file with comments | « no previous file | PRESUBMIT_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698