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

Side by Side Diff: isolate.py

Issue 51383003: Report all swarming and isolate fatal errors in a consistent way. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/swarm_client
Patch Set: make isolate_smoke_test less strict regarding exact contents of stderr Created 7 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | isolateserver.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 """Front end tool to operate on .isolate files. 6 """Front end tool to operate on .isolate files.
7 7
8 This includes creating, merging or compiling them to generate a .isolated file. 8 This includes creating, merging or compiling them to generate a .isolated file.
9 9
10 See more information at 10 See more information at
(...skipping 2431 matching lines...) Expand 10 before | Expand all | Expand 10 after
2442 # there. 2442 # there.
2443 options.outdir = os.path.normpath(os.path.join(cwd, options.outdir)) 2443 options.outdir = os.path.normpath(os.path.join(cwd, options.outdir))
2444 2444
2445 return options, args 2445 return options, args
2446 2446
2447 2447
2448 def main(argv): 2448 def main(argv):
2449 dispatcher = subcommand.CommandDispatcher(__name__) 2449 dispatcher = subcommand.CommandDispatcher(__name__)
2450 try: 2450 try:
2451 return dispatcher.execute(OptionParserIsolate(version=__version__), argv) 2451 return dispatcher.execute(OptionParserIsolate(version=__version__), argv)
2452 except ( 2452 except Exception as e:
2453 ExecutionError, 2453 tools.report_error(e)
2454 isolateserver.ConfigError,
2455 isolateserver.MappingError) as e:
2456 sys.stderr.write('\nError: ')
2457 sys.stderr.write(str(e))
2458 sys.stderr.write('\n')
2459 return 1 2454 return 1
2460 2455
2461 2456
2462 if __name__ == '__main__': 2457 if __name__ == '__main__':
2463 fix_encoding.fix_encoding() 2458 fix_encoding.fix_encoding()
2464 tools.disable_buffering() 2459 tools.disable_buffering()
2465 colorama.init() 2460 colorama.init()
2466 sys.exit(main(sys.argv[1:])) 2461 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « no previous file | isolateserver.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698