donate-cpu: only retry uploading package if it did not work

This commit is contained in:
Daniel Marjamäki 2018-11-28 19:30:14 +01:00
parent dd94bfede9
commit 15d0aa503b
1 changed files with 2 additions and 1 deletions

View File

@ -259,11 +259,12 @@ def uploadResults(package, results):
sock.connect(server_address)
sendAll(sock, 'write\n' + package + '\n' + results + '\nDONE')
sock.close()
return True
except socket.error:
print('Upload failed, retry in 60 seconds')
time.sleep(30)
pass
return package
return False
jobs = '-j1'
stopTime = None