Browse Source

fix for seqrun file copy

Avik Datta 4 years ago
parent
commit
bf4d31825b
1 changed files with 11 additions and 3 deletions
  1. 11 3
      dags/dag8_copy_ongoing_seqrun.py

+ 11 - 3
dags/dag8_copy_ongoing_seqrun.py

@@ -206,15 +206,23 @@ def copy_seqrun_chunk(**context):
     if finish_index > len(file_data) - 1:
       finish_index = len(file_data) - 1
     local_seqrun_path = \
-      os.path.join(local_seqrun_path,seqrun_id)
+      os.path.join(
+        local_seqrun_path,
+        seqrun_id)
+    remote_seqrun_path = \
+      os.path.join(
+        seqrun_base_path,
+        seqrun_id)
     remote_address = \
-      '{0}@{1}'.format(seqrun_server_user,seqrun_server)
+      '{0}@{1}'.format(
+        seqrun_server_user,
+        seqrun_server)
     for entry in file_data[start_index:finish_index]:
       file_path = entry.get('file_path')
       file_size = entry.get('file_size')
       remote_path = \
         os.path.join(
-          seqrun_base_path,
+          remote_seqrun_path,
           file_path)
       local_path = \
         os.path.join(