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

Side by Side Diff: build/android/buildbot/bb_run_bot.py

Issue 307963002: os.rename instead of shutil.move (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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 # 2 #
3 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 3 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 import collections 7 import collections
8 import copy 8 import copy
9 import json 9 import json
10 import os 10 import os
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 print >> sys.stderr, hostname_stdout 283 print >> sys.stderr, hostname_stdout
284 print >> sys.stderr, hostname_stderr 284 print >> sys.stderr, hostname_stderr
285 sys.exit(1) 285 sys.exit(1)
286 286
287 # TODO(phajdan.jr): Remove hack for http://crbug.com/378779 . 287 # TODO(phajdan.jr): Remove hack for http://crbug.com/378779 .
288 if hostname_stdout == 'build1-a1.perf.chromium.org': 288 if hostname_stdout == 'build1-a1.perf.chromium.org':
289 if os.path.exists('/b/build/slave/Android_Builder__dbg_378779'): 289 if os.path.exists('/b/build/slave/Android_Builder__dbg_378779'):
290 print '/b/build/slave/Android_Builder__dbg_378779 exists, skipping' 290 print '/b/build/slave/Android_Builder__dbg_378779 exists, skipping'
291 else: 291 else:
292 print 'CLEANING UP CHECKOUT DIRECTORY HACK SEE http://crbug.com/378779' 292 print 'CLEANING UP CHECKOUT DIRECTORY HACK SEE http://crbug.com/378779'
293 shutil.move('/b/build/slave/Android_Builder__dbg_', 293 os.rename('/b/build/slave/Android_Builder__dbg_',
294 '/b/build/slave/Android_Builder__dbg_378779') 294 '/b/build/slave/Android_Builder__dbg_378779')
295 295
296 parser = GetRunBotOptParser() 296 parser = GetRunBotOptParser()
297 options, args = parser.parse_args(argv[1:]) 297 options, args = parser.parse_args(argv[1:])
298 if args: 298 if args:
299 parser.error('Unused args: %s' % args) 299 parser.error('Unused args: %s' % args)
300 300
301 bot_config = GetBotConfig(options, GetBotStepMap()) 301 bot_config = GetBotConfig(options, GetBotStepMap())
302 if not bot_config: 302 if not bot_config:
303 sys.exit(1) 303 sys.exit(1)
304 304
305 print 'Using config:', bot_config 305 print 'Using config:', bot_config
306 306
307 commands = GetCommands(options, bot_config) 307 commands = GetCommands(options, bot_config)
308 for command in commands: 308 for command in commands:
309 print 'Will run: ', bb_utils.CommandToString(command) 309 print 'Will run: ', bb_utils.CommandToString(command)
310 print 310 print
311 311
312 env = GetEnvironment(bot_config.host_obj, options.testing) 312 env = GetEnvironment(bot_config.host_obj, options.testing)
313 return RunBotCommands(options, commands, env) 313 return RunBotCommands(options, commands, env)
314 314
315 315
316 if __name__ == '__main__': 316 if __name__ == '__main__':
317 sys.exit(main(sys.argv)) 317 sys.exit(main(sys.argv))
OLDNEW
« 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