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

Side by Side Diff: client/swarming.py

Issue 2093593002: luci-py: Making __file__ usage unicode safe. (Closed) Base URL: https://github.com/luci/luci-py.git@master
Patch Set: Small fixes. Created 4 years, 5 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
« no previous file with comments | « client/run_isolated.py ('k') | client/tests/file_path_test.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 2013 The LUCI Authors. All rights reserved. 2 # Copyright 2013 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 """Client tool to trigger tasks or retrieve results from a Swarming server.""" 6 """Client tool to trigger tasks or retrieve results from a Swarming server."""
7 7
8 __version__ = '0.8.6' 8 __version__ = '0.8.6'
9 9
10 import collections 10 import collections
(...skipping 22 matching lines...) Expand all
33 from utils import subprocess42 33 from utils import subprocess42
34 from utils import threading_utils 34 from utils import threading_utils
35 from utils import tools 35 from utils import tools
36 36
37 import auth 37 import auth
38 import isolated_format 38 import isolated_format
39 import isolateserver 39 import isolateserver
40 import run_isolated 40 import run_isolated
41 41
42 42
43 ROOT_DIR = os.path.dirname(os.path.abspath(__file__)) 43 ROOT_DIR = os.path.dirname(os.path.abspath(
44 __file__.decode(sys.getfilesystemencoding())))
44 45
45 46
46 class Failure(Exception): 47 class Failure(Exception):
47 """Generic failure.""" 48 """Generic failure."""
48 pass 49 pass
49 50
50 51
51 ### Isolated file handling. 52 ### Isolated file handling.
52 53
53 54
(...skipping 1538 matching lines...) Expand 10 before | Expand all | Expand 10 after
1592 dispatcher = subcommand.CommandDispatcher(__name__) 1593 dispatcher = subcommand.CommandDispatcher(__name__)
1593 return dispatcher.execute(OptionParserSwarming(version=__version__), args) 1594 return dispatcher.execute(OptionParserSwarming(version=__version__), args)
1594 1595
1595 1596
1596 if __name__ == '__main__': 1597 if __name__ == '__main__':
1597 subprocess42.inhibit_os_error_reporting() 1598 subprocess42.inhibit_os_error_reporting()
1598 fix_encoding.fix_encoding() 1599 fix_encoding.fix_encoding()
1599 tools.disable_buffering() 1600 tools.disable_buffering()
1600 colorama.init() 1601 colorama.init()
1601 sys.exit(main(sys.argv[1:])) 1602 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « client/run_isolated.py ('k') | client/tests/file_path_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698