From 9ed25c4ff9550f1ab4b15e4f2380af8ea1eaf7ea Mon Sep 17 00:00:00 2001 From: Francesco Siddi Date: Thu, 6 Nov 2014 16:47:16 +0100 Subject: [PATCH] Assert for existing file --- webservice/bam/application/__init__.py | 1 + 1 file changed, 1 insertion(+) diff --git a/webservice/bam/application/__init__.py b/webservice/bam/application/__init__.py index 72a79be..cc179f0 100644 --- a/webservice/bam/application/__init__.py +++ b/webservice/bam/application/__init__.py @@ -241,6 +241,7 @@ class FileAPI(Resource): import shutil for src_file_path, dst_file_path in path_remap.items(): + assert(os.path.exists(os.path.join(extract_tmp_dir, src_file_path))) shutil.move( os.path.join(extract_tmp_dir, src_file_path), os.path.join(project.repository_path, dst_file_path))