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

Side by Side Diff: recipes.py

Issue 2378903002: Annotation protobuf code can now dump final. (Closed)
Patch Set: Rebase, add unit test. Created 4 years, 2 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 unified diff | Download patch
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright 2015 The LUCI Authors. All rights reserved. 2 # Copyright 2015 The LUCI Authors. All rights reserved.
3 # Use of this source code is governed under the Apache License, Version 2.0 3 # Use of this source code is governed under the Apache License, Version 2.0
4 # that can be found in the LICENSE file. 4 # that can be found in the LICENSE file.
5 5
6 """Tool to interact with recipe repositories. 6 """Tool to interact with recipe repositories.
7 7
8 This tool operates on the nearest ancestor directory containing an 8 This tool operates on the nearest ancestor directory containing an
9 infra/config/recipes.cfg. 9 infra/config/recipes.cfg.
10 """ 10 """
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 emit_timestamps=(args.timestamps or 172 emit_timestamps=(args.timestamps or
173 op_args.annotation_flags.emit_timestamp), 173 op_args.annotation_flags.emit_timestamp),
174 ) 174 )
175 175
176 stream_engines = [] 176 stream_engines = []
177 if op_args.logdog.streamserver_uri: 177 if op_args.logdog.streamserver_uri:
178 logging.debug('Using LogDog with parameters: [%s]', op_args.logdog) 178 logging.debug('Using LogDog with parameters: [%s]', op_args.logdog)
179 stream_engines.append(stream_logdog.StreamEngine( 179 stream_engines.append(stream_logdog.StreamEngine(
180 streamserver_uri=op_args.logdog.streamserver_uri, 180 streamserver_uri=op_args.logdog.streamserver_uri,
181 name_base=(op_args.logdog.name_base or None), 181 name_base=(op_args.logdog.name_base or None),
182 dump_path=op_args.logdog.final_annotation_dump_path,
182 )) 183 ))
183 184
184 # If we're teeing, also fold in a standard annotation stream engine. 185 # If we're teeing, also fold in a standard annotation stream engine.
185 if op_args.logdog.tee: 186 if op_args.logdog.tee:
186 stream_engines.append(build_annotation_stream_engine()) 187 stream_engines.append(build_annotation_stream_engine())
187 else: 188 else:
188 # Not using LogDog; use a standard annotation stream engine. 189 # Not using LogDog; use a standard annotation stream engine.
189 stream_engines.append(build_annotation_stream_engine()) 190 stream_engines.append(build_annotation_stream_engine())
190 multi_stream_engine = stream.MultiStreamEngine.create(*stream_engines) 191 multi_stream_engine = stream.MultiStreamEngine.create(*stream_engines)
191 192
(...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after
607 608
608 if not isinstance(ret, int): 609 if not isinstance(ret, int):
609 if ret is None: 610 if ret is None:
610 ret = 0 611 ret = 0
611 else: 612 else:
612 print >> sys.stderr, ret 613 print >> sys.stderr, ret
613 ret = 1 614 ret = 1
614 sys.stdout.flush() 615 sys.stdout.flush()
615 sys.stderr.flush() 616 sys.stderr.flush()
616 os._exit(ret) 617 os._exit(ret)
OLDNEW
« recipe_engine/stream_logdog.py ('K') | « recipe_engine/unittests/stream_logdog_test.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698