From a7b21cf7bb91b87cf8d39592f5e4acccc49687aa Mon Sep 17 00:00:00 2001 From: Cristiano Urban Date: Mon, 23 Aug 2021 12:28:43 +0200 Subject: [PATCH] Added 'close()' instruction. Signed-off-by: Cristiano Urban --- transfer_service/tape_client.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/transfer_service/tape_client.py b/transfer_service/tape_client.py index edce101..9dc57d3 100644 --- a/transfer_service/tape_client.py +++ b/transfer_service/tape_client.py @@ -155,6 +155,7 @@ class TapeClient(object): else: for f in fileList: fp.write(f"{f}\n") + fp.close() self.copy(f"./{tmp}", f"/tmp/{tmp}") os.remove(f"./{tmp}") cmd = f"{self.EEADM} migrate /tmp/{tmp} -p {tapePool}" @@ -188,6 +189,7 @@ class TapeClient(object): else: for f in fileList: fp.write(f"{f}\n") + fp.close() self.copy(f"./{tmp}", f"/tmp/{tmp}") os.remove(f"./{tmp}") cmd = f"{self.EEADM} recall /tmp/{tmp}" -- GitLab