| OLD | NEW |
| 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 Loading... |
| 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 Loading... |
| 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:])) |
| OLD | NEW |