Critical problem to generate approval by python

Critical problem to generate approval by python

Hi I'm Sergi.
We have updated to the last version of ServiceDesk Plus.
We have some serious problems to generate approvals by python's script.
In previous versions all our python scripts works correctly.
But now don't work, in previous version we could see in the historials tag if there was an error in script, now not
Attach our python script if your wants to try


#!/usr/bin/python

import sys
import json
import urllib
import pyodbc;


file = open(sys.argv[1], encoding="utf-8-sig")


data=json.load(file)


data_string = json.dumps(data)


decoded = json.loads(data_string)


WORKORDERID = decoded["request"]["WORKORDERID"]
Requester = decoded["request"]["REQUESTER"]

workorderid = decoded["request"]["WORKORDERID"]


peticio = int(workorderid)


RI = "personalmail@gmail.com"

resultjson={}
resultjson["operation"] = []
resultjson["result"]="success"
message = "Aprobacion 1 generada de manera automatica " + RI
detailsJSON1={}
resultjson["message"]=message
operationJson={"INPUT_DATA":[]}
operationJson["OPERATIONNAME"]="ADD_APPROVAL_STAGE"
approvalArray={}     
approvalObject=  RI
approvalArray={"StageOne":[]}
approvalArray['StageOne'].append(approvalObject);
approvalArray['StageOne'].append( RI  );
operationJson['INPUT_DATA'].append(approvalArray)
resultjson['operation'].append(operationJson)       

print(resultjson)











Please it's very urgent.
Regards

                  New to ADSelfService Plus?