LingxinMeng 7 meses atrás
pai
commit
81d6a68fd6

+ 0 - 8
src/python2/pjibot_delivery/2simulation-pjibot_delivery.py

@@ -110,7 +110,6 @@ if __name__ == '__main__':
     while True:
         try:
             logging.info("开始新一轮扫描")
-            local_delete_list = []
             oss_delete_list = []
             prefix_list = []
             # 2 获取已经上传完成的所有目录并分组
@@ -144,18 +143,11 @@ if __name__ == '__main__':
                         if not os.path.exists(root_path1):
                             os.makedirs(root_path1)
                         bucket.get_object_to_file(parse_prefix_full + xoscName, root_path1 + 'scenario_orig.xosc')
-                        local_delete_list.append(root_path1 + 'scenario_orig.xosc')
                         move_xosc_before_simulation(root_path1)
                         simulation(parse_prefix_full, root_path1 + 'simulation.mp4')
                 except Exception as e:
                     logging.exception("局部异常处理: %s", str(e))
             # 删除本地临时文件
-            if len(local_delete_list) > 0:
-                for local_delete in local_delete_list:
-                    try:
-                        os.remove(local_delete)
-                    except Exception as e:
-                        pass
             time.sleep(sleep_time)
         except Exception as e:
             logging.exception("全局异常处理: %s", str(e))

+ 0 - 9
src/python2/pjibot_delivery/simulation-pjibot_delivery.py

@@ -119,7 +119,6 @@ if __name__ == '__main__':
     while True:
         try:
             logging.info("开始新一轮扫描")
-            local_delete_list = []
             oss_delete_list = []
             prefix_list = []
             # 2 获取已经上传完成的所有目录并分组
@@ -153,18 +152,10 @@ if __name__ == '__main__':
                         if not os.path.exists(root_path1):
                             os.makedirs(root_path1)
                         bucket.get_object_to_file(parse_prefix_full + xoscName, root_path1 + 'scenario_orig.xosc')
-                        local_delete_list.append(root_path1 + 'scenario_orig.xosc')
                         move_xosc_before_simulation(root_path1)
                         simulation(parse_prefix_full, root_path1 + 'simulation.mp4')
                 except Exception as e:
                     logging.exception("局部异常处理: %s", str(e))
-            # 删除本地临时文件
-            if len(local_delete_list) > 0:
-                for local_delete in local_delete_list:
-                    try:
-                        os.remove(local_delete)
-                    except Exception as e:
-                        pass
             time.sleep(sleep_time)
         except Exception as e:
             logging.exception("全局异常处理: %s", str(e))

+ 0 - 18
src/python2/pjibot_patrol/simulation-pjibot_partol.py

@@ -113,15 +113,6 @@ def is_upload_completed(bucket, prefix):
     return int(count) == int(target_number)
 
 
-'''
-cname:http://open-bucket.oss.icvdc.com
-keyid:n8glvFGS25MrLY7j
-secret:xZ2Fozoarpfw0z28FUhtg8cu0yDc5d
-oss桶名: oss://open-bucket
-
-oss桶名: open-bucket
-内网endpoint: oss-cn-beijing-gqzl-d01-a.ops.gqzl-cloud.com
-'''
 # ------- 获取合并之后的bag包,解析出csv -------
 if __name__ == '__main__':
     # 1 创建阿里云对象
@@ -131,7 +122,6 @@ if __name__ == '__main__':
     while True:
         try:
             logging.info("开始新一轮扫描")
-            local_delete_list = []
             oss_delete_list = []
             prefix_list = []
             # 2 获取已经上传完成的所有目录并分组
@@ -165,18 +155,10 @@ if __name__ == '__main__':
                         if not os.path.exists(root_path1):
                             os.makedirs(root_path1)
                         bucket.get_object_to_file(parse_prefix_full + xoscName, root_path1 + 'scenario_orig.xosc')
-                        local_delete_list.append(root_path1 + 'scenario_orig.xosc')
                         move_xosc_before_simulation(root_path1)
                         simulation(parse_prefix_full, root_path1 + 'simulation.mp4')
                 except Exception as e:
                     logging.exception("局部异常处理: %s", str(e))
-            # 删除本地临时文件
-            if len(local_delete_list) > 0:
-                for local_delete in local_delete_list:
-                    try:
-                        os.remove(local_delete)
-                    except Exception as e:
-                        pass
             time.sleep(sleep_time)
         except Exception as e:
             logging.exception("全局异常处理: %s", str(e))