Skip to content

Commit 7930ab1

Browse files
authored
Update cp-worker.py (#71)
1 parent 7fc9838 commit 7930ab1

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

worker/cp-worker.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,12 +165,15 @@ def runCellProfiler(message):
165165
cmd = 'aws s3 mv ' + localOut + ' s3://' + AWS_BUCKET + '/' + remoteOut + ' --recursive'
166166
subp = subprocess.Popen(cmd.split(), stdout=subprocess.PIPE, stderr=subprocess.PIPE)
167167
out,err = subp.communicate()
168-
printandlog('== OUT /n'+out, logger)
168+
printandlog('== OUT \n'+out, logger)
169169
if err == '':
170170
break
171+
else:
172+
printandlog('== ERR \n'+err,logger)
173+
mvtries+=1
171174
except:
172175
printandlog('Move failed',logger)
173-
printandlog('== ERR /n'+err,logger)
176+
printandlog('== ERR \n'+err,logger)
174177
time.sleep(30)
175178
mvtries+=1
176179
if mvtries<3:

0 commit comments

Comments
 (0)