design batch 代码整理

This commit is contained in:
alab
2024-09-26 06:09:05 +00:00
parent a539923207
commit 04b15aa200
33 changed files with 585 additions and 61 deletions

View File

@@ -0,0 +1,13 @@
import json
import logging
logger = logging.getLogger()
def oss_upload_json(oss_client, json_data, object_name):
try:
with open(f"app/service/design_batch/response_json/{object_name}", 'w') as file:
json.dump(json_data, file, indent=4)
oss_client.fput_object("test", object_name, f"app/service/design_batch/response_json/{object_name}")
except Exception as e:
logger.warning(str(e))