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

Unified Diff: presubmit_support.py

Issue 1825063003: depot_tools: remove code for --trybot-json (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: Created 4 years, 9 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: presubmit_support.py
diff --git a/presubmit_support.py b/presubmit_support.py
index 3f873c0d83af11246dba1c788b6ff6d24912b102..2b01bc356401cea34d7634b6ab87d3ba120a893b 100755
--- a/presubmit_support.py
+++ b/presubmit_support.py
@@ -1650,6 +1650,7 @@ def main(argv=None):
parser.add_option("--rietveld_email_file", help=optparse.SUPPRESS_HELP)
parser.add_option("--rietveld_private_key_file", help=optparse.SUPPRESS_HELP)
+ # TODO(phajdan.jr): Update callers and remove obsolete --trybot-json .
parser.add_option("--trybot-json",
help="Output trybot information to the file specified.")
auth.add_auth_options(parser)
@@ -1696,32 +1697,6 @@ def main(argv=None):
options.description = props['description']
logging.info('Got author: "%s"', options.author)
logging.info('Got description: """\n%s\n"""', options.description)
- if options.trybot_json:
- with open(options.trybot_json, 'w') as f:
- # Python's sets aren't JSON-encodable, so we convert them to lists here.
- class SetEncoder(json.JSONEncoder):
- # pylint: disable=E0202
- def default(self, obj):
- if isinstance(obj, set):
- return sorted(obj)
- return json.JSONEncoder.default(self, obj)
- change = change_class(options.name,
- options.description,
- options.root,
- files,
- options.issue,
- options.patchset,
- options.author,
- upstream=options.upstream)
- trybots = DoGetTrySlaves(
- change,
- change.LocalPaths(),
- change.RepositoryRoot(),
- None,
- None,
- options.verbose,
- sys.stdout)
- json.dump(trybots, f, cls=SetEncoder)
try:
with canned_check_filter(options.skip_canned):
results = DoPresubmitChecks(
« 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