From fc31b6a65a68ebbc3bc8885f722a62f2de9014c8 Mon Sep 17 00:00:00 2001 From: venkataakhil Date: Tue, 23 May 2023 09:39:44 +0530 Subject: [PATCH] Publish testing --- smart_service/apis/publish_api.py | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/smart_service/apis/publish_api.py b/smart_service/apis/publish_api.py index ebcd89d..cb06874 100644 --- a/smart_service/apis/publish_api.py +++ b/smart_service/apis/publish_api.py @@ -339,19 +339,6 @@ def new_publish(args, publish_type, vehicle, language, version): @frappe.whitelist() def merge_json_files(old_json_path, new_json_path, out_file_path): - # old_json_path = '/home/ubuntu/frappe-bench/sites/guidedsmartservice.com/public/files/json_files/full_update/XUV 0613/XUV 0613-en-full_v1.0.json' - # new_json_path = '/home/ubuntu/frappe-bench/sites/guidedsmartservice.com/public/files/json_files/global/XUV 0613/XUV 0613-en_v2.00.json' - # out_file_path = '/home/ubuntu/frappe-bench/sites/guidedsmartservice.com/public/files/json_files/full_update/XUV 0613/XUV 0613-en-full_update_test.json' - - # return old_json_path,new_json_path,out_file_path - # rate_res = custom_rate_limit(limit=5, seconds=15) - # if rate_res != 1: - # return rate_res - # val = input_validation(old_json_path=old_json_path, - # new_json_path=new_json_path, out_file_path=out_file_path) - # if val != '': - # return {status: 0, error: "Parameter missing :" + val} - try: with open(old_json_path, 'r') as json_file: data_old = json.load(json_file) @@ -562,7 +549,6 @@ def merge_json_files(old_json_path, new_json_path, out_file_path): return True, out_file_path except Exception as e: return False, frappe.get_traceback() - # return "Exception in publish" @frappe.whitelist() @@ -876,7 +862,7 @@ def upv(): # frappe.db.commit() return 1 - +""" Generate publish """ @frappe.whitelist() def run_publish(): new_publish('THAR-en -2023-05-21 16:57:54.119826',