Permalink
Browse files

bug 698804 - sign_android.py will now fatal() on a failed download. r…

…=nthomas
  • Loading branch information...
1 parent 5d4cca0 commit a0d79052cf74d912f56572fef8eee6f4260f569c @escapewindow escapewindow committed Jan 8, 2013
Showing with 13 additions and 6 deletions.
  1. +6 −4 mozharness/base/script.py
  2. +7 −2 scripts/sign_android.py
View
@@ -833,10 +833,12 @@ def query_failure(self, key):
return key in self.failures
def summarize_success_count(self, success_count, total_count,
- message="%d of %d successful."):
- level = INFO
- if success_count < total_count:
- level = ERROR
+ message="%d of %d successful.",
+ level=None):
+ if level is None:
+ level = INFO
+ if success_count < total_count:
+ level = ERROR
self.add_summary(message % (success_count, total_count),
level=level)
View
@@ -18,7 +18,7 @@
# load modules from parent dir
sys.path.insert(1, os.path.dirname(sys.path[0]))
-from mozharness.base.log import ERROR, FATAL
+from mozharness.base.log import INFO, ERROR, FATAL
from mozharness.base.transfer import TransferMixin
from mozharness.mozilla.release import ReleaseMixin
from mozharness.mozilla.signing import MobileSigningMixin
@@ -210,8 +210,13 @@ def download_unsigned_bits(self):
message="Unable to download %(platform)s:%(locale)s unsigned apk!")
else:
success_count += 1
+ level = INFO
+ # fatal() if we fail to download (bug 827226)
+ if success_count < total_count:
+ level = FATAL
self.summarize_success_count(success_count, total_count,
- message="Downloaded %d of %d unsigned apks successfully.")
+ message="Downloaded %d of %d unsigned apks successfully.",
+ level=level)
if c['enable_partner_repacks']:
self.info("Downloading partner-repacks")
if replace_dict.get('platform'):

0 comments on commit a0d7905

Please sign in to comment.