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

Unified Diff: tools/metrics/histograms/presubmit_scheme_histograms.py

Issue 2841823007: Fix presubmit_scheme_histograms.py and presubmit_bad_message_reasons.py (Closed)
Patch Set: Fix an old typo in _RunHistogramChecks. Created 3 years, 8 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
Index: tools/metrics/histograms/presubmit_scheme_histograms.py
diff --git a/tools/metrics/histograms/presubmit_scheme_histograms.py b/tools/metrics/histograms/presubmit_scheme_histograms.py
index 4adccb98def363041970ae7740597614f880d256..9d7aa70994c6eb6544a7d5aa3bc134a962de01f8 100644
--- a/tools/metrics/histograms/presubmit_scheme_histograms.py
+++ b/tools/metrics/histograms/presubmit_scheme_histograms.py
@@ -18,14 +18,13 @@ def PrecheckShouldAllowOpenURLEnums(input_api, output_api):
if source_file not in affected_files:
return []
- if update_histogram_enum.HistogramNeedsUpdate(
+ presubmit_error = update_histogram_enum.CheckPresubmitErrors(
histogram_enum_name='ShouldAllowOpenURLFailureScheme',
+ update_script_name='update_should_allow_open_url_histograms.py',
source_enum_path=source_file,
start_marker='^enum ShouldAllowOpenURLFailureScheme {',
- end_marker='^SCHEME_LAST'):
- return [output_api.PresubmitPromptWarning(
- 'ShouldAllowOpenURLFailureScheme has been updated but histogram.xml '
- 'does not appear to be updated.\nPlease run:\n'
- ' python tools/metrics/histograms/'
- 'update_should_allow_open_url_histograms.py\n')]
+ end_marker='^SCHEME_LAST')
+ if presubmit_error:
+ return [output_api.PresubmitPromptWarning(presubmit_error,
+ items=[source_file])]
return []
« no previous file with comments | « tools/metrics/histograms/presubmit_bad_message_reasons.py ('k') | tools/metrics/histograms/update_histogram_enum.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698