OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2006-2009 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 """\ | 6 """\ |
7 Wrapper script around Rietveld's upload.py that simplifies working with groups | 7 Wrapper script around Rietveld's upload.py that simplifies working with groups |
8 of files. | 8 of files. |
9 """ | 9 """ |
10 | 10 |
(...skipping 1316 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1327 return CMDpassthru(argv) | 1327 return CMDpassthru(argv) |
1328 except gclient_utils.Error, e: | 1328 except gclient_utils.Error, e: |
1329 print >> sys.stderr, 'Got an exception' | 1329 print >> sys.stderr, 'Got an exception' |
1330 print >> sys.stderr, str(e) | 1330 print >> sys.stderr, str(e) |
1331 return 1 | 1331 return 1 |
1332 except urllib2.HTTPError, e: | 1332 except urllib2.HTTPError, e: |
1333 if e.code != 500: | 1333 if e.code != 500: |
1334 raise | 1334 raise |
1335 print >> sys.stderr, ( | 1335 print >> sys.stderr, ( |
1336 'AppEngine is misbehaving and returned HTTP %d, again. Keep faith ' | 1336 'AppEngine is misbehaving and returned HTTP %d, again. Keep faith ' |
1337 'and retry or visit go/isgaeup.\n%s') % (e.code, e.reason) | 1337 'and retry or visit go/isgaeup.\n%s') % (e.code, str(e)) |
1338 return 1 | 1338 return 1 |
1339 | 1339 |
1340 | 1340 |
1341 if __name__ == "__main__": | 1341 if __name__ == "__main__": |
1342 sys.exit(main(sys.argv[1:])) | 1342 sys.exit(main(sys.argv[1:])) |
OLD | NEW |