[email protected] | a18130a | 2012-01-03 17:52:08 | [diff] [blame] | 1 | # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
[email protected] | ca8d198 | 2009-02-19 16:33:12 | [diff] [blame] | 2 | # Use of this source code is governed by a BSD-style license that can be |
| 3 | # found in the LICENSE file. |
| 4 | |
| 5 | """Top-level presubmit script for Chromium. |
| 6 | |
[email protected] | f129379 | 2009-07-31 18:09:56 | [diff] [blame] | 7 | See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts |
[email protected] | 50d7d721e | 2009-11-15 17:56:18 | [diff] [blame] | 8 | for more details about the presubmit API built into gcl. |
[email protected] | ca8d198 | 2009-02-19 16:33:12 | [diff] [blame] | 9 | """ |
| 10 | |
[email protected] | eea609a | 2011-11-18 13:10:12 | [diff] [blame] | 11 | |
[email protected] | 9d16ad1 | 2011-12-14 20:49:47 | [diff] [blame] | 12 | import re |
[email protected] | fbcafe5a | 2012-08-08 15:31:22 | [diff] [blame] | 13 | import subprocess |
[email protected] | 55f9f38 | 2012-07-31 11:02:18 | [diff] [blame] | 14 | import sys |
[email protected] | 9d16ad1 | 2011-12-14 20:49:47 | [diff] [blame] | 15 | |
| 16 | |
[email protected] | 379e7dd | 2010-01-28 17:39:21 | [diff] [blame] | 17 | _EXCLUDED_PATHS = ( |
[email protected] | 3e4eb11 | 2011-01-18 03:29:54 | [diff] [blame] | 18 | r"^breakpad[\\\/].*", |
[email protected] | 40d1dbb | 2012-10-26 07:18:00 | [diff] [blame] | 19 | r"^native_client_sdk[\\\/]src[\\\/]build_tools[\\\/]make_rules.py", |
| 20 | r"^native_client_sdk[\\\/]src[\\\/]build_tools[\\\/]make_simple.py", |
[email protected] | a18130a | 2012-01-03 17:52:08 | [diff] [blame] | 21 | r"^net[\\\/]tools[\\\/]spdyshark[\\\/].*", |
[email protected] | 3e4eb11 | 2011-01-18 03:29:54 | [diff] [blame] | 22 | r"^skia[\\\/].*", |
| 23 | r"^v8[\\\/].*", |
| 24 | r".*MakeFile$", |
[email protected] | 1084ccc | 2012-03-14 03:22:53 | [diff] [blame] | 25 | r".+_autogen\.h$", |
[email protected] | 94f206c1 | 2012-08-25 00:09:14 | [diff] [blame] | 26 | r"^cc[\\\/].*", |
[email protected] | 39849c6c | 2012-09-14 22:15:59 | [diff] [blame] | 27 | r"^webkit[\\\/]compositor_bindings[\\\/].*", |
[email protected] | ce145c0 | 2012-09-06 09:49:34 | [diff] [blame] | 28 | r".+[\\\/]pnacl_shim\.c$", |
[email protected] | 430641764 | 2009-06-11 00:33:40 | [diff] [blame] | 29 | ) |
[email protected] | ca8d198 | 2009-02-19 16:33:12 | [diff] [blame] | 30 | |
[email protected] | ca8d198 | 2009-02-19 16:33:12 | [diff] [blame] | 31 | |
[email protected] | eea609a | 2011-11-18 13:10:12 | [diff] [blame] | 32 | _TEST_ONLY_WARNING = ( |
| 33 | 'You might be calling functions intended only for testing from\n' |
| 34 | 'production code. It is OK to ignore this warning if you know what\n' |
| 35 | 'you are doing, as the heuristics used to detect the situation are\n' |
| 36 | 'not perfect. The commit queue will not block on this warning.\n' |
| 37 | 'Email [email protected] if you have questions.') |
| 38 | |
| 39 | |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 40 | _BANNED_OBJC_FUNCTIONS = ( |
| 41 | ( |
| 42 | 'addTrackingRect:', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 43 | ( |
| 44 | 'The use of -[NSView addTrackingRect:owner:userData:assumeInside:] is' |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 45 | 'prohibited. Please use CrTrackingArea instead.', |
| 46 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 47 | ), |
| 48 | False, |
| 49 | ), |
| 50 | ( |
| 51 | 'NSTrackingArea', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 52 | ( |
| 53 | 'The use of NSTrackingAreas is prohibited. Please use CrTrackingArea', |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 54 | 'instead.', |
| 55 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 56 | ), |
| 57 | False, |
| 58 | ), |
| 59 | ( |
| 60 | 'convertPointFromBase:', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 61 | ( |
| 62 | 'The use of -[NSView convertPointFromBase:] is almost certainly wrong.', |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 63 | 'Please use |convertPoint:(point) fromView:nil| instead.', |
| 64 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 65 | ), |
| 66 | True, |
| 67 | ), |
| 68 | ( |
| 69 | 'convertPointToBase:', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 70 | ( |
| 71 | 'The use of -[NSView convertPointToBase:] is almost certainly wrong.', |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 72 | 'Please use |convertPoint:(point) toView:nil| instead.', |
| 73 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 74 | ), |
| 75 | True, |
| 76 | ), |
| 77 | ( |
| 78 | 'convertRectFromBase:', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 79 | ( |
| 80 | 'The use of -[NSView convertRectFromBase:] is almost certainly wrong.', |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 81 | 'Please use |convertRect:(point) fromView:nil| instead.', |
| 82 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 83 | ), |
| 84 | True, |
| 85 | ), |
| 86 | ( |
| 87 | 'convertRectToBase:', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 88 | ( |
| 89 | 'The use of -[NSView convertRectToBase:] is almost certainly wrong.', |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 90 | 'Please use |convertRect:(point) toView:nil| instead.', |
| 91 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 92 | ), |
| 93 | True, |
| 94 | ), |
| 95 | ( |
| 96 | 'convertSizeFromBase:', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 97 | ( |
| 98 | 'The use of -[NSView convertSizeFromBase:] is almost certainly wrong.', |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 99 | 'Please use |convertSize:(point) fromView:nil| instead.', |
| 100 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 101 | ), |
| 102 | True, |
| 103 | ), |
| 104 | ( |
| 105 | 'convertSizeToBase:', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 106 | ( |
| 107 | 'The use of -[NSView convertSizeToBase:] is almost certainly wrong.', |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 108 | 'Please use |convertSize:(point) toView:nil| instead.', |
| 109 | 'http://dev.chromium.org/developers/coding-style/cocoa-dos-and-donts', |
| 110 | ), |
| 111 | True, |
| 112 | ), |
| 113 | ) |
| 114 | |
| 115 | |
| 116 | _BANNED_CPP_FUNCTIONS = ( |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 117 | # Make sure that gtest's FRIEND_TEST() macro is not used; the |
| 118 | # FRIEND_TEST_ALL_PREFIXES() macro from base/gtest_prod_util.h should be |
[email protected] | e00ccc9 | 2012-11-01 17:32:30 | [diff] [blame] | 119 | # used instead since that allows for FLAKY_ and DISABLED_ prefixes. |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 120 | ( |
| 121 | 'FRIEND_TEST(', |
| 122 | ( |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 123 | 'Chromium code should not use gtest\'s FRIEND_TEST() macro. Include', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 124 | 'base/gtest_prod_util.h and use FRIEND_TEST_ALL_PREFIXES() instead.', |
| 125 | ), |
| 126 | False, |
| 127 | ), |
| 128 | ( |
| 129 | 'ScopedAllowIO', |
| 130 | ( |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 131 | 'New code should not use ScopedAllowIO. Post a task to the blocking', |
| 132 | 'pool or the FILE thread instead.', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 133 | ), |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 134 | True, |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 135 | ), |
| 136 | ( |
| 137 | 'FilePathWatcher::Delegate', |
| 138 | ( |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 139 | 'New code should not use FilePathWatcher::Delegate. Use the callback', |
[email protected] | 23e6cbc | 2012-06-16 18:51:20 | [diff] [blame] | 140 | 'interface instead.', |
| 141 | ), |
| 142 | False, |
| 143 | ), |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 144 | ( |
[email protected] | aebced3 | 2012-11-12 01:32:20 | [diff] [blame^] | 145 | 'chrome::FindLastActiveWithProfile', |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 146 | ( |
| 147 | 'This function is deprecated and we\'re working on removing it. Pass', |
| 148 | 'more context to get a Browser*, like a WebContents, window, or session', |
[email protected] | 1099dbd | 2012-11-01 19:56:02 | [diff] [blame] | 149 | 'id. Talk to robertshield@ for more information.', |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 150 | ), |
| 151 | True, |
| 152 | ), |
| 153 | ( |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 154 | 'browser::FindAnyBrowser', |
| 155 | ( |
| 156 | 'This function is deprecated and we\'re working on removing it. Pass', |
| 157 | 'more context to get a Browser*, like a WebContents, window, or session', |
[email protected] | 1099dbd | 2012-11-01 19:56:02 | [diff] [blame] | 158 | 'id. Talk to robertshield@ for more information.', |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 159 | ), |
| 160 | True, |
| 161 | ), |
| 162 | ( |
| 163 | 'browser::FindOrCreateTabbedBrowser', |
| 164 | ( |
| 165 | 'This function is deprecated and we\'re working on removing it. Pass', |
| 166 | 'more context to get a Browser*, like a WebContents, window, or session', |
[email protected] | 1099dbd | 2012-11-01 19:56:02 | [diff] [blame] | 167 | 'id. Talk to robertshield@ for more information.', |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 168 | ), |
| 169 | True, |
| 170 | ), |
| 171 | ( |
[email protected] | 1099dbd | 2012-11-01 19:56:02 | [diff] [blame] | 172 | 'browser::FindTabbedBrowserDeprecated', |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 173 | ( |
| 174 | 'This function is deprecated and we\'re working on removing it. Pass', |
| 175 | 'more context to get a Browser*, like a WebContents, window, or session', |
[email protected] | 1099dbd | 2012-11-01 19:56:02 | [diff] [blame] | 176 | 'id. Talk to robertshield@ for more information.', |
[email protected] | e3c94550 | 2012-06-26 20:01:49 | [diff] [blame] | 177 | ), |
| 178 | True, |
| 179 | ), |
[email protected] | bb5eff1cc | 2012-11-01 20:46:29 | [diff] [blame] | 180 | ( |
| 181 | 'RunAllPending()', |
| 182 | ( |
| 183 | 'This function is deprecated and we\'re working on removing it. Rename', |
| 184 | 'to RunUntilIdle', |
| 185 | ), |
| 186 | True, |
| 187 | ), |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 188 | ) |
| 189 | |
| 190 | |
[email protected] | eea609a | 2011-11-18 13:10:12 | [diff] [blame] | 191 | |
[email protected] | 5545985 | 2011-08-10 15:17:19 | [diff] [blame] | 192 | def _CheckNoProductionCodeUsingTestOnlyFunctions(input_api, output_api): |
| 193 | """Attempts to prevent use of functions intended only for testing in |
| 194 | non-testing code. For now this is just a best-effort implementation |
| 195 | that ignores header files and may have some false positives. A |
| 196 | better implementation would probably need a proper C++ parser. |
| 197 | """ |
| 198 | # We only scan .cc files and the like, as the declaration of |
| 199 | # for-testing functions in header files are hard to distinguish from |
| 200 | # calls to such functions without a proper C++ parser. |
[email protected] | 403bfbc9 | 2012-06-11 23:30:09 | [diff] [blame] | 201 | platform_specifiers = r'(_(android|chromeos|gtk|mac|posix|win))?' |
[email protected] | 5545985 | 2011-08-10 15:17:19 | [diff] [blame] | 202 | source_extensions = r'\.(cc|cpp|cxx|mm)$' |
| 203 | file_inclusion_pattern = r'.+%s' % source_extensions |
[email protected] | 19e77fd | 2011-10-20 05:24:05 | [diff] [blame] | 204 | file_exclusion_patterns = ( |
[email protected] | 44e376e | 2012-10-26 19:40:21 | [diff] [blame] | 205 | r'.*[/\\](fake_|test_|mock_).+%s' % source_extensions, |
[email protected] | c762d25 | 2012-02-28 02:07:24 | [diff] [blame] | 206 | r'.+_test_(base|support|util)%s' % source_extensions, |
[email protected] | 403bfbc9 | 2012-06-11 23:30:09 | [diff] [blame] | 207 | r'.+_(api|browser|perf|unit|ui)?test%s%s' % (platform_specifiers, |
| 208 | source_extensions), |
[email protected] | 19e77fd | 2011-10-20 05:24:05 | [diff] [blame] | 209 | r'.+profile_sync_service_harness%s' % source_extensions, |
| 210 | ) |
| 211 | path_exclusion_patterns = ( |
| 212 | r'.*[/\\](test|tool(s)?)[/\\].*', |
| 213 | # At request of folks maintaining this folder. |
| 214 | r'chrome[/\\]browser[/\\]automation[/\\].*', |
| 215 | ) |
[email protected] | 5545985 | 2011-08-10 15:17:19 | [diff] [blame] | 216 | |
| 217 | base_function_pattern = r'ForTest(ing)?|for_test(ing)?' |
| 218 | inclusion_pattern = input_api.re.compile(r'(%s)\s*\(' % base_function_pattern) |
| 219 | exclusion_pattern = input_api.re.compile( |
| 220 | r'::[A-Za-z0-9_]+(%s)|(%s)[^;]+\{' % ( |
| 221 | base_function_pattern, base_function_pattern)) |
| 222 | |
| 223 | def FilterFile(affected_file): |
[email protected] | 19e77fd | 2011-10-20 05:24:05 | [diff] [blame] | 224 | black_list = (file_exclusion_patterns + path_exclusion_patterns + |
[email protected] | 3afb12a4 | 2011-08-15 13:48:33 | [diff] [blame] | 225 | _EXCLUDED_PATHS + input_api.DEFAULT_BLACK_LIST) |
[email protected] | 5545985 | 2011-08-10 15:17:19 | [diff] [blame] | 226 | return input_api.FilterSourceFile( |
| 227 | affected_file, |
| 228 | white_list=(file_inclusion_pattern, ), |
| 229 | black_list=black_list) |
| 230 | |
| 231 | problems = [] |
| 232 | for f in input_api.AffectedSourceFiles(FilterFile): |
| 233 | local_path = f.LocalPath() |
| 234 | lines = input_api.ReadFile(f).splitlines() |
| 235 | line_number = 0 |
| 236 | for line in lines: |
| 237 | if (inclusion_pattern.search(line) and |
| 238 | not exclusion_pattern.search(line)): |
| 239 | problems.append( |
| 240 | '%s:%d\n %s' % (local_path, line_number, line.strip())) |
| 241 | line_number += 1 |
| 242 | |
| 243 | if problems: |
[email protected] | eea609a | 2011-11-18 13:10:12 | [diff] [blame] | 244 | if not input_api.is_committing: |
| 245 | return [output_api.PresubmitPromptWarning(_TEST_ONLY_WARNING, problems)] |
| 246 | else: |
| 247 | # We don't warn on commit, to avoid stopping commits going through CQ. |
| 248 | return [output_api.PresubmitNotifyResult(_TEST_ONLY_WARNING, problems)] |
[email protected] | 5545985 | 2011-08-10 15:17:19 | [diff] [blame] | 249 | else: |
| 250 | return [] |
| 251 | |
| 252 | |
[email protected] | 10689ca | 2011-09-02 02:31:54 | [diff] [blame] | 253 | def _CheckNoIOStreamInHeaders(input_api, output_api): |
| 254 | """Checks to make sure no .h files include <iostream>.""" |
| 255 | files = [] |
| 256 | pattern = input_api.re.compile(r'^#include\s*<iostream>', |
| 257 | input_api.re.MULTILINE) |
| 258 | for f in input_api.AffectedSourceFiles(input_api.FilterSourceFile): |
| 259 | if not f.LocalPath().endswith('.h'): |
| 260 | continue |
| 261 | contents = input_api.ReadFile(f) |
| 262 | if pattern.search(contents): |
| 263 | files.append(f) |
| 264 | |
| 265 | if len(files): |
| 266 | return [ output_api.PresubmitError( |
[email protected] | 6c063c6 | 2012-07-11 19:11:06 | [diff] [blame] | 267 | 'Do not #include <iostream> in header files, since it inserts static ' |
| 268 | 'initialization into every file including the header. Instead, ' |
[email protected] | 10689ca | 2011-09-02 02:31:54 | [diff] [blame] | 269 | '#include <ostream>. See http://crbug.com/94794', |
| 270 | files) ] |
| 271 | return [] |
| 272 | |
| 273 | |
[email protected] | 72df4e78 | 2012-06-21 16:28:18 | [diff] [blame] | 274 | def _CheckNoUNIT_TESTInSourceFiles(input_api, output_api): |
| 275 | """Checks to make sure no source files use UNIT_TEST""" |
| 276 | problems = [] |
| 277 | for f in input_api.AffectedFiles(): |
| 278 | if (not f.LocalPath().endswith(('.cc', '.mm'))): |
| 279 | continue |
| 280 | |
| 281 | for line_num, line in f.ChangedContents(): |
| 282 | if 'UNIT_TEST' in line: |
| 283 | problems.append(' %s:%d' % (f.LocalPath(), line_num)) |
| 284 | |
| 285 | if not problems: |
| 286 | return [] |
| 287 | return [output_api.PresubmitPromptWarning('UNIT_TEST is only for headers.\n' + |
| 288 | '\n'.join(problems))] |
| 289 | |
| 290 | |
[email protected] | 8ea5d4b | 2011-09-13 21:49:22 | [diff] [blame] | 291 | def _CheckNoNewWStrings(input_api, output_api): |
| 292 | """Checks to make sure we don't introduce use of wstrings.""" |
[email protected] | 55463aa6 | 2011-10-12 00:48:27 | [diff] [blame] | 293 | problems = [] |
[email protected] | 8ea5d4b | 2011-09-13 21:49:22 | [diff] [blame] | 294 | for f in input_api.AffectedFiles(): |
[email protected] | b5c2429 | 2011-11-28 14:38:20 | [diff] [blame] | 295 | if (not f.LocalPath().endswith(('.cc', '.h')) or |
| 296 | f.LocalPath().endswith('test.cc')): |
| 297 | continue |
[email protected] | 8ea5d4b | 2011-09-13 21:49:22 | [diff] [blame] | 298 | |
[email protected] | a11dbe9b | 2012-08-07 01:32:58 | [diff] [blame] | 299 | allowWString = False |
[email protected] | b5c2429 | 2011-11-28 14:38:20 | [diff] [blame] | 300 | for line_num, line in f.ChangedContents(): |
[email protected] | a11dbe9b | 2012-08-07 01:32:58 | [diff] [blame] | 301 | if 'presubmit: allow wstring' in line: |
| 302 | allowWString = True |
| 303 | elif not allowWString and 'wstring' in line: |
[email protected] | 55463aa6 | 2011-10-12 00:48:27 | [diff] [blame] | 304 | problems.append(' %s:%d' % (f.LocalPath(), line_num)) |
[email protected] | a11dbe9b | 2012-08-07 01:32:58 | [diff] [blame] | 305 | allowWString = False |
| 306 | else: |
| 307 | allowWString = False |
[email protected] | 8ea5d4b | 2011-09-13 21:49:22 | [diff] [blame] | 308 | |
[email protected] | 55463aa6 | 2011-10-12 00:48:27 | [diff] [blame] | 309 | if not problems: |
| 310 | return [] |
| 311 | return [output_api.PresubmitPromptWarning('New code should not use wstrings.' |
[email protected] | a11dbe9b | 2012-08-07 01:32:58 | [diff] [blame] | 312 | ' If you are calling a cross-platform API that accepts a wstring, ' |
| 313 | 'fix the API.\n' + |
[email protected] | 55463aa6 | 2011-10-12 00:48:27 | [diff] [blame] | 314 | '\n'.join(problems))] |
[email protected] | 8ea5d4b | 2011-09-13 21:49:22 | [diff] [blame] | 315 | |
| 316 | |
[email protected] | 2a8ac9c | 2011-10-19 17:20:44 | [diff] [blame] | 317 | def _CheckNoDEPSGIT(input_api, output_api): |
| 318 | """Make sure .DEPS.git is never modified manually.""" |
| 319 | if any(f.LocalPath().endswith('.DEPS.git') for f in |
| 320 | input_api.AffectedFiles()): |
| 321 | return [output_api.PresubmitError( |
| 322 | 'Never commit changes to .DEPS.git. This file is maintained by an\n' |
| 323 | 'automated system based on what\'s in DEPS and your changes will be\n' |
| 324 | 'overwritten.\n' |
| 325 | 'See http://code.google.com/p/chromium/wiki/UsingNewGit#Rolling_DEPS\n' |
| 326 | 'for more information')] |
| 327 | return [] |
| 328 | |
| 329 | |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 330 | def _CheckNoBannedFunctions(input_api, output_api): |
| 331 | """Make sure that banned functions are not used.""" |
| 332 | warnings = [] |
| 333 | errors = [] |
| 334 | |
| 335 | file_filter = lambda f: f.LocalPath().endswith(('.mm', '.m', '.h')) |
| 336 | for f in input_api.AffectedFiles(file_filter=file_filter): |
| 337 | for line_num, line in f.ChangedContents(): |
| 338 | for func_name, message, error in _BANNED_OBJC_FUNCTIONS: |
| 339 | if func_name in line: |
| 340 | problems = warnings; |
| 341 | if error: |
| 342 | problems = errors; |
| 343 | problems.append(' %s:%d:' % (f.LocalPath(), line_num)) |
| 344 | for message_line in message: |
| 345 | problems.append(' %s' % message_line) |
| 346 | |
| 347 | file_filter = lambda f: f.LocalPath().endswith(('.cc', '.mm', '.h')) |
| 348 | for f in input_api.AffectedFiles(file_filter=file_filter): |
| 349 | for line_num, line in f.ChangedContents(): |
| 350 | for func_name, message, error in _BANNED_CPP_FUNCTIONS: |
| 351 | if func_name in line: |
| 352 | problems = warnings; |
| 353 | if error: |
| 354 | problems = errors; |
| 355 | problems.append(' %s:%d:' % (f.LocalPath(), line_num)) |
| 356 | for message_line in message: |
| 357 | problems.append(' %s' % message_line) |
| 358 | |
| 359 | result = [] |
| 360 | if (warnings): |
| 361 | result.append(output_api.PresubmitPromptWarning( |
| 362 | 'Banned functions were used.\n' + '\n'.join(warnings))) |
| 363 | if (errors): |
| 364 | result.append(output_api.PresubmitError( |
| 365 | 'Banned functions were used.\n' + '\n'.join(errors))) |
| 366 | return result |
| 367 | |
| 368 | |
[email protected] | 6c063c6 | 2012-07-11 19:11:06 | [diff] [blame] | 369 | def _CheckNoPragmaOnce(input_api, output_api): |
| 370 | """Make sure that banned functions are not used.""" |
| 371 | files = [] |
| 372 | pattern = input_api.re.compile(r'^#pragma\s+once', |
| 373 | input_api.re.MULTILINE) |
| 374 | for f in input_api.AffectedSourceFiles(input_api.FilterSourceFile): |
| 375 | if not f.LocalPath().endswith('.h'): |
| 376 | continue |
| 377 | contents = input_api.ReadFile(f) |
| 378 | if pattern.search(contents): |
| 379 | files.append(f) |
| 380 | |
| 381 | if files: |
| 382 | return [output_api.PresubmitError( |
| 383 | 'Do not use #pragma once in header files.\n' |
| 384 | 'See http://www.chromium.org/developers/coding-style#TOC-File-headers', |
| 385 | files)] |
| 386 | return [] |
| 387 | |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 388 | |
[email protected] | e747905 | 2012-09-19 00:26:12 | [diff] [blame] | 389 | def _CheckNoTrinaryTrueFalse(input_api, output_api): |
| 390 | """Checks to make sure we don't introduce use of foo ? true : false.""" |
| 391 | problems = [] |
| 392 | pattern = input_api.re.compile(r'\?\s*(true|false)\s*:\s*(true|false)') |
| 393 | for f in input_api.AffectedFiles(): |
| 394 | if not f.LocalPath().endswith(('.cc', '.h', '.inl', '.m', '.mm')): |
| 395 | continue |
| 396 | |
| 397 | for line_num, line in f.ChangedContents(): |
| 398 | if pattern.match(line): |
| 399 | problems.append(' %s:%d' % (f.LocalPath(), line_num)) |
| 400 | |
| 401 | if not problems: |
| 402 | return [] |
| 403 | return [output_api.PresubmitPromptWarning( |
| 404 | 'Please consider avoiding the "? true : false" pattern if possible.\n' + |
| 405 | '\n'.join(problems))] |
| 406 | |
| 407 | |
[email protected] | 55f9f38 | 2012-07-31 11:02:18 | [diff] [blame] | 408 | def _CheckUnwantedDependencies(input_api, output_api): |
| 409 | """Runs checkdeps on #include statements added in this |
| 410 | change. Breaking - rules is an error, breaking ! rules is a |
| 411 | warning. |
| 412 | """ |
| 413 | # We need to wait until we have an input_api object and use this |
| 414 | # roundabout construct to import checkdeps because this file is |
| 415 | # eval-ed and thus doesn't have __file__. |
| 416 | original_sys_path = sys.path |
| 417 | try: |
| 418 | sys.path = sys.path + [input_api.os_path.join( |
| 419 | input_api.PresubmitLocalPath(), 'tools', 'checkdeps')] |
| 420 | import checkdeps |
| 421 | from cpp_checker import CppChecker |
| 422 | from rules import Rule |
| 423 | finally: |
| 424 | # Restore sys.path to what it was before. |
| 425 | sys.path = original_sys_path |
| 426 | |
| 427 | added_includes = [] |
| 428 | for f in input_api.AffectedFiles(): |
| 429 | if not CppChecker.IsCppFile(f.LocalPath()): |
| 430 | continue |
| 431 | |
| 432 | changed_lines = [line for line_num, line in f.ChangedContents()] |
| 433 | added_includes.append([f.LocalPath(), changed_lines]) |
| 434 | |
| 435 | deps_checker = checkdeps.DepsChecker() |
| 436 | |
| 437 | error_descriptions = [] |
| 438 | warning_descriptions = [] |
| 439 | for path, rule_type, rule_description in deps_checker.CheckAddedCppIncludes( |
| 440 | added_includes): |
| 441 | description_with_path = '%s\n %s' % (path, rule_description) |
| 442 | if rule_type == Rule.DISALLOW: |
| 443 | error_descriptions.append(description_with_path) |
| 444 | else: |
| 445 | warning_descriptions.append(description_with_path) |
| 446 | |
| 447 | results = [] |
| 448 | if error_descriptions: |
| 449 | results.append(output_api.PresubmitError( |
| 450 | 'You added one or more #includes that violate checkdeps rules.', |
| 451 | error_descriptions)) |
| 452 | if warning_descriptions: |
[email protected] | 779caa5 | 2012-08-21 17:05:59 | [diff] [blame] | 453 | if not input_api.is_committing: |
| 454 | warning_factory = output_api.PresubmitPromptWarning |
| 455 | else: |
| 456 | # We don't want to block use of the CQ when there is a warning |
| 457 | # of this kind, so we only show a message when committing. |
| 458 | warning_factory = output_api.PresubmitNotifyResult |
| 459 | results.append(warning_factory( |
[email protected] | 55f9f38 | 2012-07-31 11:02:18 | [diff] [blame] | 460 | 'You added one or more #includes of files that are temporarily\n' |
| 461 | 'allowed but being removed. Can you avoid introducing the\n' |
| 462 | '#include? See relevant DEPS file(s) for details and contacts.', |
| 463 | warning_descriptions)) |
| 464 | return results |
| 465 | |
| 466 | |
[email protected] | fbcafe5a | 2012-08-08 15:31:22 | [diff] [blame] | 467 | def _CheckFilePermissions(input_api, output_api): |
| 468 | """Check that all files have their permissions properly set.""" |
| 469 | args = [sys.executable, 'tools/checkperms/checkperms.py', '--root', |
| 470 | input_api.change.RepositoryRoot()] |
| 471 | for f in input_api.AffectedFiles(): |
| 472 | args += ['--file', f.LocalPath()] |
| 473 | errors = [] |
| 474 | (errors, stderrdata) = subprocess.Popen(args).communicate() |
| 475 | |
| 476 | results = [] |
| 477 | if errors: |
[email protected] | c8278b3 | 2012-10-30 20:35:49 | [diff] [blame] | 478 | results.append(output_api.PresubmitError('checkperms.py failed.', |
[email protected] | fbcafe5a | 2012-08-08 15:31:22 | [diff] [blame] | 479 | errors)) |
| 480 | return results |
| 481 | |
| 482 | |
[email protected] | c8278b3 | 2012-10-30 20:35:49 | [diff] [blame] | 483 | def _CheckNoAuraWindowPropertyHInHeaders(input_api, output_api): |
| 484 | """Makes sure we don't include ui/aura/window_property.h |
| 485 | in header files. |
| 486 | """ |
| 487 | pattern = input_api.re.compile(r'^#include\s*"ui/aura/window_property.h"') |
| 488 | errors = [] |
| 489 | for f in input_api.AffectedFiles(): |
| 490 | if not f.LocalPath().endswith('.h'): |
| 491 | continue |
| 492 | for line_num, line in f.ChangedContents(): |
| 493 | if pattern.match(line): |
| 494 | errors.append(' %s:%d' % (f.LocalPath(), line_num)) |
| 495 | |
| 496 | results = [] |
| 497 | if errors: |
| 498 | results.append(output_api.PresubmitError( |
| 499 | 'Header files should not include ui/aura/window_property.h', errors)) |
| 500 | return results |
| 501 | |
| 502 | |
[email protected] | 22c9bd7 | 2011-03-27 16:47:39 | [diff] [blame] | 503 | def _CommonChecks(input_api, output_api): |
| 504 | """Checks common to both upload and commit.""" |
| 505 | results = [] |
| 506 | results.extend(input_api.canned_checks.PanProjectChecks( |
| 507 | input_api, output_api, excluded_paths=_EXCLUDED_PATHS)) |
[email protected] | 66daa70 | 2011-05-28 14:41:46 | [diff] [blame] | 508 | results.extend(_CheckAuthorizedAuthor(input_api, output_api)) |
[email protected] | 5545985 | 2011-08-10 15:17:19 | [diff] [blame] | 509 | results.extend( |
| 510 | _CheckNoProductionCodeUsingTestOnlyFunctions(input_api, output_api)) |
[email protected] | 10689ca | 2011-09-02 02:31:54 | [diff] [blame] | 511 | results.extend(_CheckNoIOStreamInHeaders(input_api, output_api)) |
[email protected] | 72df4e78 | 2012-06-21 16:28:18 | [diff] [blame] | 512 | results.extend(_CheckNoUNIT_TESTInSourceFiles(input_api, output_api)) |
[email protected] | 8ea5d4b | 2011-09-13 21:49:22 | [diff] [blame] | 513 | results.extend(_CheckNoNewWStrings(input_api, output_api)) |
[email protected] | 2a8ac9c | 2011-10-19 17:20:44 | [diff] [blame] | 514 | results.extend(_CheckNoDEPSGIT(input_api, output_api)) |
[email protected] | 127f18ec | 2012-06-16 05:05:59 | [diff] [blame] | 515 | results.extend(_CheckNoBannedFunctions(input_api, output_api)) |
[email protected] | 6c063c6 | 2012-07-11 19:11:06 | [diff] [blame] | 516 | results.extend(_CheckNoPragmaOnce(input_api, output_api)) |
[email protected] | e747905 | 2012-09-19 00:26:12 | [diff] [blame] | 517 | results.extend(_CheckNoTrinaryTrueFalse(input_api, output_api)) |
[email protected] | 55f9f38 | 2012-07-31 11:02:18 | [diff] [blame] | 518 | results.extend(_CheckUnwantedDependencies(input_api, output_api)) |
[email protected] | fbcafe5a | 2012-08-08 15:31:22 | [diff] [blame] | 519 | results.extend(_CheckFilePermissions(input_api, output_api)) |
[email protected] | c8278b3 | 2012-10-30 20:35:49 | [diff] [blame] | 520 | results.extend(_CheckNoAuraWindowPropertyHInHeaders(input_api, output_api)) |
[email protected] | 22c9bd7 | 2011-03-27 16:47:39 | [diff] [blame] | 521 | return results |
[email protected] | 1f7b417 | 2010-01-28 01:17:34 | [diff] [blame] | 522 | |
[email protected] | b337cb5b | 2011-01-23 21:24:05 | [diff] [blame] | 523 | |
| 524 | def _CheckSubversionConfig(input_api, output_api): |
| 525 | """Verifies the subversion config file is correctly setup. |
| 526 | |
| 527 | Checks that autoprops are enabled, returns an error otherwise. |
| 528 | """ |
| 529 | join = input_api.os_path.join |
| 530 | if input_api.platform == 'win32': |
| 531 | appdata = input_api.environ.get('APPDATA', '') |
| 532 | if not appdata: |
| 533 | return [output_api.PresubmitError('%APPDATA% is not configured.')] |
| 534 | path = join(appdata, 'Subversion', 'config') |
| 535 | else: |
| 536 | home = input_api.environ.get('HOME', '') |
| 537 | if not home: |
| 538 | return [output_api.PresubmitError('$HOME is not configured.')] |
| 539 | path = join(home, '.subversion', 'config') |
| 540 | |
| 541 | error_msg = ( |
| 542 | 'Please look at http://dev.chromium.org/developers/coding-style to\n' |
| 543 | 'configure your subversion configuration file. This enables automatic\n' |
[email protected] | c6a3c10b | 2011-01-24 16:14:20 | [diff] [blame] | 544 | 'properties to simplify the project maintenance.\n' |
| 545 | 'Pro-tip: just download and install\n' |
| 546 | 'http://src.chromium.org/viewvc/chrome/trunk/tools/build/slave/config\n') |
[email protected] | b337cb5b | 2011-01-23 21:24:05 | [diff] [blame] | 547 | |
| 548 | try: |
| 549 | lines = open(path, 'r').read().splitlines() |
| 550 | # Make sure auto-props is enabled and check for 2 Chromium standard |
| 551 | # auto-prop. |
| 552 | if (not '*.cc = svn:eol-style=LF' in lines or |
| 553 | not '*.pdf = svn:mime-type=application/pdf' in lines or |
| 554 | not 'enable-auto-props = yes' in lines): |
| 555 | return [ |
[email protected] | 79ed7e6 | 2011-02-21 21:08:53 | [diff] [blame] | 556 | output_api.PresubmitNotifyResult( |
[email protected] | b337cb5b | 2011-01-23 21:24:05 | [diff] [blame] | 557 | 'It looks like you have not configured your subversion config ' |
[email protected] | b5359c0 | 2011-02-01 20:29:56 | [diff] [blame] | 558 | 'file or it is not up-to-date.\n' + error_msg) |
[email protected] | b337cb5b | 2011-01-23 21:24:05 | [diff] [blame] | 559 | ] |
| 560 | except (OSError, IOError): |
| 561 | return [ |
[email protected] | 79ed7e6 | 2011-02-21 21:08:53 | [diff] [blame] | 562 | output_api.PresubmitNotifyResult( |
[email protected] | b337cb5b | 2011-01-23 21:24:05 | [diff] [blame] | 563 | 'Can\'t find your subversion config file.\n' + error_msg) |
| 564 | ] |
| 565 | return [] |
| 566 | |
| 567 | |
[email protected] | 66daa70 | 2011-05-28 14:41:46 | [diff] [blame] | 568 | def _CheckAuthorizedAuthor(input_api, output_api): |
| 569 | """For non-googler/chromites committers, verify the author's email address is |
| 570 | in AUTHORS. |
| 571 | """ |
[email protected] | 9bb9cb8 | 2011-06-13 20:43:01 | [diff] [blame] | 572 | # TODO(maruel): Add it to input_api? |
| 573 | import fnmatch |
| 574 | |
[email protected] | 66daa70 | 2011-05-28 14:41:46 | [diff] [blame] | 575 | author = input_api.change.author_email |
[email protected] | 9bb9cb8 | 2011-06-13 20:43:01 | [diff] [blame] | 576 | if not author: |
| 577 | input_api.logging.info('No author, skipping AUTHOR check') |
[email protected] | 66daa70 | 2011-05-28 14:41:46 | [diff] [blame] | 578 | return [] |
[email protected] | c9966329 | 2011-05-31 19:46:08 | [diff] [blame] | 579 | authors_path = input_api.os_path.join( |
[email protected] | 66daa70 | 2011-05-28 14:41:46 | [diff] [blame] | 580 | input_api.PresubmitLocalPath(), 'AUTHORS') |
| 581 | valid_authors = ( |
| 582 | input_api.re.match(r'[^#]+\s+\<(.+?)\>\s*$', line) |
| 583 | for line in open(authors_path)) |
[email protected] | ac54b13 | 2011-06-06 18:11:18 | [diff] [blame] | 584 | valid_authors = [item.group(1).lower() for item in valid_authors if item] |
[email protected] | 9bb9cb8 | 2011-06-13 20:43:01 | [diff] [blame] | 585 | if input_api.verbose: |
| 586 | print 'Valid authors are %s' % ', '.join(valid_authors) |
[email protected] | d8b50be | 2011-06-15 14:19:44 | [diff] [blame] | 587 | if not any(fnmatch.fnmatch(author.lower(), valid) for valid in valid_authors): |
[email protected] | 66daa70 | 2011-05-28 14:41:46 | [diff] [blame] | 588 | return [output_api.PresubmitPromptWarning( |
| 589 | ('%s is not in AUTHORS file. If you are a new contributor, please visit' |
| 590 | '\n' |
| 591 | 'http://www.chromium.org/developers/contributing-code and read the ' |
| 592 | '"Legal" section\n' |
| 593 | 'If you are a chromite, verify the contributor signed the CLA.') % |
| 594 | author)] |
| 595 | return [] |
| 596 | |
| 597 | |
[email protected] | 1f7b417 | 2010-01-28 01:17:34 | [diff] [blame] | 598 | def CheckChangeOnUpload(input_api, output_api): |
| 599 | results = [] |
| 600 | results.extend(_CommonChecks(input_api, output_api)) |
[email protected] | fe5f57c5 | 2009-06-05 14:25:54 | [diff] [blame] | 601 | return results |
[email protected] | ca8d198 | 2009-02-19 16:33:12 | [diff] [blame] | 602 | |
| 603 | |
| 604 | def CheckChangeOnCommit(input_api, output_api): |
[email protected] | fe5f57c5 | 2009-06-05 14:25:54 | [diff] [blame] | 605 | results = [] |
[email protected] | 1f7b417 | 2010-01-28 01:17:34 | [diff] [blame] | 606 | results.extend(_CommonChecks(input_api, output_api)) |
[email protected] | dd805fe | 2009-10-01 08:11:51 | [diff] [blame] | 607 | # TODO(thestig) temporarily disabled, doesn't work in third_party/ |
| 608 | #results.extend(input_api.canned_checks.CheckSvnModifiedDirectories( |
| 609 | # input_api, output_api, sources)) |
[email protected] | fe5f57c5 | 2009-06-05 14:25:54 | [diff] [blame] | 610 | # Make sure the tree is 'open'. |
[email protected] | 806e98e | 2010-03-19 17:49:27 | [diff] [blame] | 611 | results.extend(input_api.canned_checks.CheckTreeIsOpen( |
[email protected] | 7f23815 | 2009-08-12 19:00:34 | [diff] [blame] | 612 | input_api, |
| 613 | output_api, |
[email protected] | 4efa4214 | 2010-08-26 01:29:26 | [diff] [blame] | 614 | json_url='http://chromium-status.appspot.com/current?format=json')) |
[email protected] | 806e98e | 2010-03-19 17:49:27 | [diff] [blame] | 615 | results.extend(input_api.canned_checks.CheckRietveldTryJobExecution(input_api, |
[email protected] | 4ddc5df | 2011-12-12 03:05:04 | [diff] [blame] | 616 | output_api, 'http://codereview.chromium.org', |
[email protected] | c1ba4c5 | 2012-03-09 14:23:28 | [diff] [blame] | 617 | ('win_rel', 'linux_rel', 'mac_rel, win:compile'), |
| 618 | '[email protected]')) |
[email protected] | 806e98e | 2010-03-19 17:49:27 | [diff] [blame] | 619 | |
[email protected] | 3e4eb11 | 2011-01-18 03:29:54 | [diff] [blame] | 620 | results.extend(input_api.canned_checks.CheckChangeHasBugField( |
| 621 | input_api, output_api)) |
[email protected] | c4b4756 | 2011-12-05 23:39:41 | [diff] [blame] | 622 | results.extend(input_api.canned_checks.CheckChangeHasDescription( |
| 623 | input_api, output_api)) |
[email protected] | b337cb5b | 2011-01-23 21:24:05 | [diff] [blame] | 624 | results.extend(_CheckSubversionConfig(input_api, output_api)) |
[email protected] | fe5f57c5 | 2009-06-05 14:25:54 | [diff] [blame] | 625 | return results |
[email protected] | ca8d198 | 2009-02-19 16:33:12 | [diff] [blame] | 626 | |
| 627 | |
[email protected] | 5efb2a82 | 2011-09-27 23:06:13 | [diff] [blame] | 628 | def GetPreferredTrySlaves(project, change): |
[email protected] | 4ce995ea | 2012-06-27 02:13:10 | [diff] [blame] | 629 | files = change.LocalPaths() |
| 630 | |
[email protected] | 3019c90 | 2012-06-29 00:09:03 | [diff] [blame] | 631 | if not files: |
| 632 | return [] |
| 633 | |
[email protected] | d668899a | 2012-09-06 18:16:59 | [diff] [blame] | 634 | if all(re.search('\.(m|mm)$|(^|[/_])mac[/_.]', f) for f in files): |
[email protected] | 641f2e3e | 2012-09-03 11:16:24 | [diff] [blame] | 635 | return ['mac_rel', 'mac_asan'] |
[email protected] | d668899a | 2012-09-06 18:16:59 | [diff] [blame] | 636 | if all(re.search('(^|[/_])win[/_.]', f) for f in files): |
[email protected] | 4ce995ea | 2012-06-27 02:13:10 | [diff] [blame] | 637 | return ['win_rel'] |
[email protected] | d668899a | 2012-09-06 18:16:59 | [diff] [blame] | 638 | if all(re.search('(^|[/_])android[/_.]', f) for f in files): |
[email protected] | 3e2f040 | 2012-11-02 16:28:01 | [diff] [blame] | 639 | return ['android_dbg', 'android_clang_dbg'] |
[email protected] | 356aa54 | 2012-09-19 23:31:29 | [diff] [blame] | 640 | if all(re.search('^native_client_sdk', f) for f in files): |
| 641 | return ['linux_nacl_sdk', 'win_nacl_sdk', 'mac_nacl_sdk'] |
[email protected] | de14215 | 2012-10-03 23:02:45 | [diff] [blame] | 642 | if all(re.search('[/_]ios[/_.]', f) for f in files): |
| 643 | return ['ios_rel_device', 'ios_dbg_simulator'] |
[email protected] | 4ce995ea | 2012-06-27 02:13:10 | [diff] [blame] | 644 | |
[email protected] | 3e2f040 | 2012-11-02 16:28:01 | [diff] [blame] | 645 | trybots = [ |
| 646 | 'android_clang_dbg', |
| 647 | 'android_dbg', |
| 648 | 'ios_dbg_simulator', |
| 649 | 'ios_rel_device', |
| 650 | 'linux_asan', |
| 651 | 'linux_chromeos', |
| 652 | 'linux_clang:compile', |
| 653 | 'linux_rel', |
| 654 | 'mac_asan', |
| 655 | 'mac_rel', |
| 656 | 'win_rel', |
| 657 | ] |
[email protected] | 911753b | 2012-08-02 12:11:54 | [diff] [blame] | 658 | |
| 659 | # Match things like path/aura/file.cc and path/file_aura.cc. |
[email protected] | 0be9553a | 2012-08-10 00:14:45 | [diff] [blame] | 660 | # Same for ash and chromeos. |
| 661 | if any(re.search('[/_](ash|aura)', f) for f in files): |
[email protected] | 3e2f040 | 2012-11-02 16:28:01 | [diff] [blame] | 662 | trybots += ['linux_chromeos_clang:compile', 'win_aura', |
[email protected] | 641f2e3e | 2012-09-03 11:16:24 | [diff] [blame] | 663 | 'linux_chromeos_asan'] |
[email protected] | 3e2f040 | 2012-11-02 16:28:01 | [diff] [blame] | 664 | elif any(re.search('[/_]chromeos', f) for f in files): |
| 665 | trybots += ['linux_chromeos_clang:compile', 'linux_chromeos_asan'] |
[email protected] | 4ce995ea | 2012-06-27 02:13:10 | [diff] [blame] | 666 | |
[email protected] | 4ce995ea | 2012-06-27 02:13:10 | [diff] [blame] | 667 | return trybots |