Be more defensive with our storage uploading
Currently we're seeing ~15 of these fail each hour,
because of an issue we're having with Azure.
Let's not fail builds on this situation.
@@ -213,6 +213,7 @@ class SelectiveStorageRemotePuller(RemotePuller):
any([target.lower().endswith(ext) for ext in cls.extensions]):
log.info('Selective Copy %s to media storage', target)
+ try:
storage_path = cls.get_storage_path(target)
if storage.exists(storage_path):
@@ -220,6 +221,8 @@ class SelectiveStorageRemotePuller(RemotePuller):
with open(target, 'rb') as fd:
storage.save(storage_path, fd)
+ except Exception:
+ log.exception('Storage access failed for file. Not failing build.')
class Syncer(SettingsOverrideObject):
